Browse Source

WARNING: MODULES RENAMING!!!

raylib modules have been slightly renamed to add some identity and note that they are independent modules that can be used as standalone separate parts of raylib if required.

The renamed modules are:
 - `core` -> `rcore`
 - `shapes` -> `rshapes`
 - `textures` -> `rtextures`
 - `text` -> `rtext`
 - `models` -> `rmodels`
 - `camera` -> `rcamera`
 - `gestures` -> `rgestures`
 - `core` -> `rcore`

All the build systems has been adapted to this change.
pull/2003/head
Ray 3 years ago
parent
commit
99ab4d6cb8
20 changed files with 57 additions and 58 deletions
  1. +7
    -7
      CMakeOptions.txt
  2. +5
    -5
      HISTORY.md
  3. +5
    -5
      projects/Geany/raylib_compile_sources.bat
  4. BIN
      projects/Notepad++/npes_saved_mingw.txt
  5. BIN
      projects/Notepad++/npes_saved_tcc.txt
  6. +7
    -7
      projects/VS2019/raylib/raylib.vcxproj
  7. +1
    -1
      projects/scripts/build-linux.sh
  8. +1
    -1
      projects/scripts/build-osx.sh
  9. +1
    -1
      projects/scripts/build-rpi.sh
  10. +1
    -1
      projects/scripts/build-windows.bat
  11. +5
    -5
      src/CMakeLists.txt
  12. +5
    -5
      src/Makefile
  13. +2
    -2
      src/config.h
  14. +3
    -3
      src/rcamera.h
  15. +6
    -6
      src/rcore.c
  16. +4
    -5
      src/rgestures.h
  17. +1
    -1
      src/rmodels.c
  18. +1
    -1
      src/rshapes.c
  19. +1
    -1
      src/rtext.c
  20. +1
    -1
      src/rtextures.c

+ 7
- 7
CMakeOptions.txt View File

@ -27,9 +27,9 @@ endif()
option(INCLUDE_EVERYTHING "Include everything disabled by default (for CI usage" OFF)
set(OFF ${INCLUDE_EVERYTHING} CACHE INTERNAL "Replace any OFF by default with \${OFF} to have it covered by this option")
# core.c
cmake_dependent_option(SUPPORT_CAMERA_SYSTEM "Provide camera module (camera.h) with multiple predefined cameras: free, 1st/3rd person, orbital" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_GESTURES_SYSTEM "Gestures module is included (gestures.h) to support gestures detection: tap, hold, swipe, drag" ON CUSTOMIZE_BUILD ON)
# rcore.c
cmake_dependent_option(SUPPORT_CAMERA_SYSTEM "Provide camera module (rcamera.h) with multiple predefined cameras: free, 1st/3rd person, orbital" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_GESTURES_SYSTEM "Gestures module is included (rgestures.h) to support gestures detection: tap, hold, swipe, drag" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_MOUSE_GESTURES "Mouse gestures are directly mapped like touches and processed by gestures system" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_SSH_KEYBOARD_RPI "Reconfigure standard input to receive key inputs, works with SSH connection" OFF CUSTOMIZE_BUILD OFF)
cmake_dependent_option(SUPPORT_DEFAULT_FONT "Default font is loaded on window initialization to be available for the user to render simple text. If enabled, uses external module functions to load default raylib font (module: text)" ON CUSTOMIZE_BUILD ON)
@ -41,10 +41,10 @@ cmake_dependent_option(SUPPORT_WINMM_HIGHRES_TIMER "Setting a higher resolution
cmake_dependent_option(SUPPORT_DATA_STORAGE "Support for persistent data storage" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_COMPRESSION_API "Support for compression API" ON CUSTOMIZE_BUILD ON)
# shapes.c
# rshapes.c
cmake_dependent_option(SUPPORT_QUADS_DRAW_MODE "Use QUADS instead of TRIANGLES for drawing when possible. Some lines-based shapes could still use lines" ON CUSTOMIZE_BUILD ON)
# textures.c
# rtextures.c
cmake_dependent_option(SUPPORT_IMAGE_EXPORT "Support image exporting to file" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_IMAGE_GENERATION "Support procedural image generation functionality (gradient, spot, perlin-noise, cellular)" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_IMAGE_MANIPULATION "Support multiple image editing functions to scale, adjust colors, flip, draw on images, crop... If not defined only three image editing functions supported: ImageFormat(), ImageAlphaMask(), ImageToPOT()" ON CUSTOMIZE_BUILD ON)
@ -61,12 +61,12 @@ cmake_dependent_option(SUPPORT_FILEFORMAT_PSD "Support loading PSD as textures"
cmake_dependent_option(SUPPORT_FILEFORMAT_PKM "Support loading PKM as textures" ${OFF} CUSTOMIZE_BUILD OFF)
cmake_dependent_option(SUPPORT_FILEFORMAT_PVR "Support loading PVR as textures" ${OFF} CUSTOMIZE_BUILD OFF)
# text.c
# rtext.c
cmake_dependent_option(SUPPORT_FILEFORMAT_FNT "Support loading fonts in FNT format" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_FILEFORMAT_TTF "Support loading font in TTF/OTF format" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_TEXT_MANIPULATION "Support text manipulation functions" ON CUSTOMIZE_BUILD ON)
# models.c
# rmodels.c
cmake_dependent_option(SUPPORT_MESH_GENERATION "Support procedural mesh generation functions, uses external par_shapes.h library. NOTE: Some generated meshes DO NOT include generated texture coordinates" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_FILEFORMAT_OBJ "Support loading OBJ file format" ON CUSTOMIZE_BUILD ON)
cmake_dependent_option(SUPPORT_FILEFORMAT_MTL "Support loading MTL file format" ON CUSTOMIZE_BUILD ON)

+ 5
- 5
HISTORY.md View File

@ -33,7 +33,7 @@ Lots of code changes and lot of testing have concluded in this amazing new rayli
notes on raylib 1.2
-------------------
On September 2014, after 5 month of raylib 1.1 release, it comes raylib 1.2. Again, this version presents a complete internal redesign of [core](https://github.com/raysan5/raylib/blob/master/src/core.c) module to support two new platforms: [Android](http://www.android.com/) and [Raspberry Pi](http://www.raspberrypi.org/).
On September 2014, after 5 month of raylib 1.1 release, it comes raylib 1.2. Again, this version presents a complete internal redesign of [core](https://github.com/raysan5/raylib/blob/master/src/rcore.c) module to support two new platforms: [Android](http://www.android.com/) and [Raspberry Pi](http://www.raspberrypi.org/).
It's been some month of really hard work to accomodate raylib to those new platforms while keeping it easy for the users. On Android, raylib manages internally the activity cicle, as well as the inputs; on Raspberry Pi, a complete raw input system has been written from scratch.
@ -54,9 +54,9 @@ On September 2015, after 1 year of raylib 1.2 release, arrives raylib 1.3. This
- Textures module has grown to support most of the internal texture formats available in OpenGL (RGB565, RGB888, RGBA5551, RGBA4444, etc.), including compressed texture formats (DXT, ETC1, ETC2, ASTC, PVRT); raylib 1.3 can load .dds, .pkm, .ktx, .astc and .pvr files.
- A brand new [camera](https://github.com/raysan5/raylib/blob/master/src/camera.c) module offers to the user multiple preconfigured ready-to-use camera systems (free camera, 1st person, 3rd person). Camera modes are very easy to use, just check examples: [core_3d_camera_free.c](https://github.com/raysan5/raylib/blob/master/examples/core_3d_camera_free.c) and [core_3d_camera_first_person.c](https://github.com/raysan5/raylib/blob/master/examples/core_3d_camera_first_person.c).
- A brand new [camera](https://github.com/raysan5/raylib/blob/master/src/rcamera.c) module offers to the user multiple preconfigured ready-to-use camera systems (free camera, 1st person, 3rd person). Camera modes are very easy to use, just check examples: [core_3d_camera_free.c](https://github.com/raysan5/raylib/blob/master/examples/core_3d_camera_free.c) and [core_3d_camera_first_person.c](https://github.com/raysan5/raylib/blob/master/examples/core_3d_camera_first_person.c).
- New [gestures](https://github.com/raysan5/raylib/blob/master/src/gestures.h) module simplifies gestures detection on Android and HTML5 programs.
- New [gestures](https://github.com/raysan5/raylib/blob/master/src/rgestures.h) module simplifies gestures detection on Android and HTML5 programs.
- [raygui](https://github.com/raysan5/raylib/blob/master/src/raygui.h), the new immediate-mode GUI module offers a set of functions to create simple user interfaces, primary intended for tools development. It's still in experimental state but already fully functional.
@ -77,7 +77,7 @@ On February 2016, after 4 months of raylib 1.3 release, it comes raylib 1.4. For
- [raymath](https://github.com/raysan5/raylib/blob/master/src/raymath.h) module has been reviewed; some bugs have been solved and the module has been converted to a header-only file for easier portability, optionally, functions can also be used as inline.
- [gestures](https://github.com/raysan5/raylib/blob/master/src/gestures.c) module has redesigned and simplified, now it can process touch events from any source, including mouse. This way, gestures system can be used on any platform providing an unified way to work with inputs and allowing the user to create multiplatform games with only one source code.
- [gestures](https://github.com/raysan5/raylib/blob/master/src/rgestures.c) module has redesigned and simplified, now it can process touch events from any source, including mouse. This way, gestures system can be used on any platform providing an unified way to work with inputs and allowing the user to create multiplatform games with only one source code.
- Raspberry Pi input system has been redesigned to better read raw inputs using generic Linux event handlers (keyboard:`stdin`, mouse:`/dev/input/mouse0`, gamepad:`/dev/input/js0`). Gamepad support has also been added (experimental).
@ -106,7 +106,7 @@ On July 2016, after 5 months of raylib 1.4 release, arrives raylib 1.5. This new
- Audio chiptunese support and mixing channels: Added support for module audio music (.xm, .mod) loading and playing. Multiple mixing channels are now also supported. All this features thanks to the amazing work of @kd7tck.
Other additions include a [2D camera system](https://github.com/raysan5/raylib/blob/master/examples/core_2d_camera.c), render textures for offline render (and most comprehensive [postprocessing](https://github.com/raysan5/raylib/blob/master/examples/shaders_postprocessing.c)) or support for legacy OpenGL 2.1 on desktop platforms.
Other additions include a [2D camera system](https://github.com/raysan5/raylib/blob/master/examples/core_2d_rcamera.c), render textures for offline render (and most comprehensive [postprocessing](https://github.com/raysan5/raylib/blob/master/examples/shaders_postprocessing.c)) or support for legacy OpenGL 2.1 on desktop platforms.
This new version is so massive that is difficult to list all the improvements, most of raylib modules have been reviewed and [rlgl](https://github.com/raysan5/raylib/blob/master/src/rlgl.c) module has been completely redesigned to accomodate to new material-lighting systems and stereo rendering. You can check [CHANGELOG](https://github.com/raysan5/raylib/blob/master/CHANGELOG) file for a more detailed list of changes.

+ 5
- 5
projects/Geany/raylib_compile_sources.bat View File

@ -18,11 +18,11 @@ cmd /c del /F libraylib.a
:: > Compile raylib modules
:: ------------------------------
gcc -O2 -c rglfw.c -Wall -I. -Iexternal/glfw/include
gcc -O2 -c core.c -std=c99 -Wall -Iexternal/glfw/include -DPLATFORM_DESKTOP -D%GRAPHICS_API%
gcc -O2 -c shapes.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c textures.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c text.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c models.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c rcore.c -std=c99 -Wall -Iexternal/glfw/include -DPLATFORM_DESKTOP -D%GRAPHICS_API%
gcc -O2 -c rshapes.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c rtextures.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c rtext.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c rmodels.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c raudio.c -std=c99 -Wall -DPLATFORM_DESKTOP
gcc -O2 -c utils.c -std=c99 -Wall -DPLATFORM_DESKTOP

BIN
projects/Notepad++/npes_saved_mingw.txt View File


BIN
projects/Notepad++/npes_saved_tcc.txt View File


+ 7
- 7
projects/VS2019/raylib/raylib.vcxproj View File

@ -303,16 +303,16 @@
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\..\..\src\raudio.c" />
<ClCompile Include="..\..\..\src\core.c" />
<ClCompile Include="..\..\..\src\models.c" />
<ClCompile Include="..\..\..\src\rcore.c" />
<ClCompile Include="..\..\..\src\rmodels.c" />
<ClCompile Include="..\..\..\src\rglfw.c" />
<ClCompile Include="..\..\..\src\shapes.c" />
<ClCompile Include="..\..\..\src\text.c" />
<ClCompile Include="..\..\..\src\textures.c" />
<ClCompile Include="..\..\..\src\rshapes.c" />
<ClCompile Include="..\..\..\src\rtext.c" />
<ClCompile Include="..\..\..\src\rtextures.c" />
<ClCompile Include="..\..\..\src\utils.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\..\src\camera.h" />
<ClInclude Include="..\..\..\src\rcamera.h" />
<ClInclude Include="..\..\..\src\config.h" />
<ClInclude Include="..\..\..\src\external\glad.h" />
<ClInclude Include="..\..\..\src\external\jar_mod.h" />
@ -324,7 +324,7 @@
<ClInclude Include="..\..\..\src\external\stb_rect_pack.h" />
<ClInclude Include="..\..\..\src\external\stb_truetype.h" />
<ClInclude Include="..\..\..\src\external\stb_vorbis.h" />
<ClInclude Include="..\..\..\src\gestures.h" />
<ClInclude Include="..\..\..\src\rgestures.h" />
<ClInclude Include="..\..\..\src\raylib.h" />
<ClInclude Include="..\..\..\src\raymath.h" />
<ClInclude Include="..\..\..\src\rlgl.h" />

+ 1
- 1
projects/scripts/build-linux.sh View File

@ -120,7 +120,7 @@ if [ ! -d "$TEMP_DIR" ]; then
mkdir -p $TEMP_DIR
cd $TEMP_DIR
RAYLIB_DEFINES="-D_DEFAULT_SOURCE -DPLATFORM_DESKTOP -DGRAPHICS_API_OPENGL_33"
RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c $RAYLIB_SRC/rglfw.c"
RAYLIB_C_FILES="$RAYLIB_SRC/rcore.c $RAYLIB_SRC/rshapes.c $RAYLIB_SRC/rtextures.c $RAYLIB_SRC/rtext.c $RAYLIB_SRC/rmodels.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c $RAYLIB_SRC/rglfw.c"
RAYLIB_INCLUDE_FLAGS="-I$RAYLIB_SRC -I$RAYLIB_SRC/external/glfw/include"
if [ -n "$REALLY_QUIET" ]; then

+ 1
- 1
projects/scripts/build-osx.sh View File

@ -120,7 +120,7 @@ if [ ! -d "$TEMP_DIR" ]; then
mkdir -p $TEMP_DIR
cd $TEMP_DIR
RAYLIB_DEFINES="-D_DEFAULT_SOURCE -DPLATFORM_DESKTOP -DGRAPHICS_API_OPENGL_33"
RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c"
RAYLIB_C_FILES="$RAYLIB_SRC/rcore.c $RAYLIB_SRC/rshapes.c $RAYLIB_SRC/rtextures.c $RAYLIB_SRC/rtext.c $RAYLIB_SRC/rmodels.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c"
RAYLIB_INCLUDE_FLAGS="-I$RAYLIB_SRC -I$RAYLIB_SRC/external/glfw/include"
if [ -n "$REALLY_QUIET" ]; then

+ 1
- 1
projects/scripts/build-rpi.sh View File

@ -120,7 +120,7 @@ if [ ! -d "$TEMP_DIR" ]; then
mkdir -p $TEMP_DIR
cd $TEMP_DIR
RAYLIB_DEFINES="-D_DEFAULT_SOURCE -DPLATFORM_RPI -DGRAPHICS_API_OPENGL_ES2"
RAYLIB_C_FILES="$RAYLIB_SRC/core.c $RAYLIB_SRC/shapes.c $RAYLIB_SRC/textures.c $RAYLIB_SRC/text.c $RAYLIB_SRC/models.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c"
RAYLIB_C_FILES="$RAYLIB_SRC/rcore.c $RAYLIB_SRC/rshapes.c $RAYLIB_SRC/rtextures.c $RAYLIB_SRC/rtext.c $RAYLIB_SRC/rmodels.c $RAYLIB_SRC/utils.c $RAYLIB_SRC/raudio.c"
RAYLIB_INCLUDE_FLAGS="-I$RAYLIB_SRC -I/opt/vc/include"
if [ -n "$REALLY_QUIET" ]; then

+ 1
- 1
projects/scripts/build-windows.bat View File

@ -167,7 +167,7 @@ IF NOT EXIST !TEMP_DIR!\ (
cd !TEMP_DIR!
REM Raylib's src folder
set "RAYLIB_DEFINES=/D_DEFAULT_SOURCE /DPLATFORM_DESKTOP /DGRAPHICS_API_OPENGL_33"
set RAYLIB_C_FILES="!RAYLIB_SRC!\core.c" "!RAYLIB_SRC!\shapes.c" "!RAYLIB_SRC!\textures.c" "!RAYLIB_SRC!\text.c" "!RAYLIB_SRC!\models.c" "!RAYLIB_SRC!\utils.c" "!RAYLIB_SRC!\raudio.c" "!RAYLIB_SRC!\rglfw.c"
set RAYLIB_C_FILES="!RAYLIB_SRC!\rcore.c" "!RAYLIB_SRC!\rshapes.c" "!RAYLIB_SRC!\rtextures.c" "!RAYLIB_SRC!\rtext.c" "!RAYLIB_SRC!\rmodels.c" "!RAYLIB_SRC!\utils.c" "!RAYLIB_SRC!\raudio.c" "!RAYLIB_SRC!\rglfw.c"
set RAYLIB_INCLUDE_FLAGS=/I"!RAYLIB_SRC!" /I"!RAYLIB_SRC!\external\glfw\include"
IF DEFINED REALLY_QUIET (

+ 5
- 5
src/CMakeLists.txt View File

@ -30,11 +30,11 @@ set(raylib_public_headers
# Sources to be compiled
set(raylib_sources
core.c
models.c
shapes.c
text.c
textures.c
rcore.c
rmodels.c
rshapes.c
rtext.c
rtextures.c
utils.c
)

+ 5
- 5
src/Makefile View File

@ -549,7 +549,7 @@ endif
# Compile all modules with their prerequisites
# Compile core module
core.o : core.c raylib.h rlgl.h utils.h raymath.h camera.h gestures.h
rcore.o : rcore.c raylib.h rlgl.h utils.h raymath.h rcamera.h rgestures.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile rglfw module
@ -557,15 +557,15 @@ rglfw.o : rglfw.c
$(CC) $(GLFW_OSX) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile shapes module
shapes.o : shapes.c raylib.h rlgl.h
rshapes.o : rshapes.c raylib.h rlgl.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile textures module
textures.o : textures.c raylib.h rlgl.h utils.h
rtextures.o : rtextures.c raylib.h rlgl.h utils.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile text module
text.o : text.c raylib.h utils.h
rtext.o : rtext.c raylib.h utils.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile utils module
@ -573,7 +573,7 @@ utils.o : utils.c utils.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM)
# Compile models module
models.o : models.c raylib.h rlgl.h raymath.h
rmodels.o : rmodels.c raylib.h rlgl.h raymath.h
$(CC) -c $< $(CFLAGS) $(INCLUDE_PATHS) -D$(PLATFORM) -D$(GRAPHICS)
# Compile audio module

+ 2
- 2
src/config.h View File

@ -28,9 +28,9 @@
//------------------------------------------------------------------------------------
// Module: core - Configuration Flags
//------------------------------------------------------------------------------------
// Camera module is included (camera.h) and multiple predefined cameras are available: free, 1st/3rd person, orbital
// Camera module is included (rcamera.h) and multiple predefined cameras are available: free, 1st/3rd person, orbital
#define SUPPORT_CAMERA_SYSTEM 1
// Gestures module is included (gestures.h) to support gestures detection: tap, hold, swipe, drag
// Gestures module is included (rgestures.h) to support gestures detection: tap, hold, swipe, drag
#define SUPPORT_GESTURES_SYSTEM 1
// Mouse gestures are directly mapped like touches and processed by gestures system
#define SUPPORT_MOUSE_GESTURES 1

src/camera.h → src/rcamera.h View File

@ -1,6 +1,6 @@
/*******************************************************************************************
*
* raylib.camera - Camera system with multiple modes support
* rcamera - Basic camera system for multiple camera modes
*
* NOTE: Memory footprint of this library is aproximately 52 bytes (global variables)
*
@ -41,8 +41,8 @@
*
**********************************************************************************************/
#ifndef CAMERA_H
#define CAMERA_H
#ifndef RCAMERA_H
#define RCAMERA_H
//----------------------------------------------------------------------------------
// Defines and Macros

src/core.c → src/rcore.c View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.core - Basic functions to manage windows, OpenGL context and input on multiple platforms
* rcore - Basic functions to manage windows, OpenGL context and input on multiple platforms
*
* PLATFORMS SUPPORTED:
* - PLATFORM_DESKTOP: Windows (Win32, Win64)
@ -39,10 +39,10 @@
* NOTE: If enabled, uses external module functions to load default raylib font (module: text)
*
* #define SUPPORT_CAMERA_SYSTEM
* Camera module is included (camera.h) and multiple predefined cameras are available: free, 1st/3rd person, orbital
* Camera module is included (rcamera.h) and multiple predefined cameras are available: free, 1st/3rd person, orbital
*
* #define SUPPORT_GESTURES_SYSTEM
* Gestures module is included (gestures.h) to support gestures detection: tap, hold, swipe, drag
* Gestures module is included (rgestures.h) to support gestures detection: tap, hold, swipe, drag
*
* #define SUPPORT_MOUSE_GESTURES
* Mouse gestures are directly mapped like touches and processed by gestures system.
@ -129,12 +129,12 @@
#if defined(SUPPORT_GESTURES_SYSTEM)
#define GESTURES_IMPLEMENTATION
#include "gestures.h" // Gestures detection functionality
#include "rgestures.h" // Gestures detection functionality
#endif
#if defined(SUPPORT_CAMERA_SYSTEM)
#define CAMERA_IMPLEMENTATION
#include "camera.h" // Camera system functionality
#include "rcamera.h" // Camera system functionality
#endif
#if defined(SUPPORT_GIF_RECORDING)
@ -6617,7 +6617,7 @@ static void PlayAutomationEvent(unsigned int frame)
{
CORE.Input.Gamepad.axisState[events[i].params[0]][events[i].params[1]] = ((float)events[i].params[2]/32768.0f);
} break;
case INPUT_GESTURE: GESTURES.current = events[i].params[0]; break; // param[0]: gesture (enum Gesture) -> gestures.h: GESTURES.current
case INPUT_GESTURE: GESTURES.current = events[i].params[0]; break; // param[0]: gesture (enum Gesture) -> rgestures.h: GESTURES.current
// Window events
case WINDOW_CLOSE: CORE.Window.shouldClose = true; break;

src/gestures.h → src/rgestures.h View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.gestures - Gestures system, gestures processing based on input events (touch/mouse)
* rgestures - Gestures system, gestures processing based on input events (touch/mouse)
*
* NOTE: Memory footprint of this library is aproximately 128 bytes (global variables)
*
@ -43,8 +43,8 @@
*
**********************************************************************************************/
#ifndef GESTURES_H
#define GESTURES_H
#ifndef RGESTURES_H
#define RGESTURES_H
#ifndef PI
#define PI 3.14159265358979323846
@ -481,8 +481,7 @@ float GetGestureDragAngle(void)
// Get distance between two pinch points
Vector2 GetGesturePinchVector(void)
{
// NOTE: The position values used for GESTURES.Pinch.distance are not modified like the position values of [core.c]-->GetTouchPosition(int index)
// NOTE: pinch distance is calculated on two touch points TOUCH_ACTION_MOVE
// NOTE: Pinch distance is calculated on two touch points TOUCH_ACTION_MOVE
return GESTURES.Pinch.vector;
}

src/models.c → src/rmodels.c View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.models - Basic functions to deal with 3d shapes and 3d models
* rmodels - Basic functions to draw 3d shapes and load and draw 3d models
*
* CONFIGURATION:
*

src/shapes.c → src/rshapes.c View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.shapes - Basic functions to draw 2d Shapes and check collisions
* rshapes - Basic functions to draw 2d shapes and check collisions
*
* CONFIGURATION:
*

src/text.c → src/rtext.c View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.text - Basic functions to load Fonts and draw Text
* rtext - Basic functions to load fonts and draw text
*
* CONFIGURATION:
*

src/textures.c → src/rtextures.c View File

@ -1,6 +1,6 @@
/**********************************************************************************************
*
* raylib.textures - Basic functions to load and draw Textures (2d)
* rtextures - Basic functions to load and draw textures
*
* CONFIGURATION:
*

Loading…
Cancel
Save