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.
This commit is contained in:
Ray 2021-09-22 00:15:06 +02:00
parent 8b3d054408
commit 99ab4d6cb8
20 changed files with 57 additions and 58 deletions

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
)

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

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

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

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;

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;
}

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:
*

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:
*

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:
*

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:
*