diff options
| author | Ray <[email protected]> | 2024-04-23 19:38:45 +0200 |
|---|---|---|
| committer | Ray <[email protected]> | 2024-04-23 19:38:45 +0200 |
| commit | f15455552da353dfb7055b6fa020ba73d71de88e (patch) | |
| tree | 86a8db28cd8650b16f35cee8a3622b655ded86c9 /src/rlgl.h | |
| parent | 4b0e25d3af79ce4c5cd94e8279473764d969cca3 (diff) | |
| download | raylib-f15455552da353dfb7055b6fa020ba73d71de88e.tar.gz raylib-f15455552da353dfb7055b6fa020ba73d71de88e.zip | |
Review formatting
Diffstat (limited to 'src/rlgl.h')
| -rw-r--r-- | src/rlgl.h | 43 |
1 files changed, 22 insertions, 21 deletions
@@ -559,10 +559,6 @@ typedef enum { extern "C" { // Prevents name mangling of functions #endif -RLAPI void rlSetClipPlanes(double near, double far); -RLAPI double rlGetCullDistanceNear(); -RLAPI double rlGetCullDistanceFar(); - RLAPI void rlMatrixMode(int mode); // Choose the current matrix to be transformed RLAPI void rlPushMatrix(void); // Push the current matrix to stack RLAPI void rlPopMatrix(void); // Pop latest inserted matrix from stack @@ -574,6 +570,9 @@ RLAPI void rlMultMatrixf(const float *matf); // Multiply the current RLAPI void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar); RLAPI void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar); RLAPI void rlViewport(int x, int y, int width, int height); // Set the viewport area +RLAPI void rlSetClipPlanes(double near, double far); // Set clip planes distances +RLAPI double rlGetCullDistanceNear(); // Get cull plane distance near +RLAPI double rlGetCullDistanceFar(); // Get cull plane distance far //------------------------------------------------------------------------------------ // Functions Declaration - Vertex level operations @@ -1087,7 +1086,6 @@ typedef void *(*rlglLoadProc)(const char *name); // OpenGL extension functions //---------------------------------------------------------------------------------- // Global Variables Definition //---------------------------------------------------------------------------------- - static double rlCullDistanceNear = RL_CULL_DISTANCE_NEAR; static double rlCullDistanceFar = RL_CULL_DISTANCE_FAR; @@ -1135,22 +1133,6 @@ static Matrix rlMatrixInvert(Matrix mat); // Invert provided m // Module Functions Definition - Matrix operations //---------------------------------------------------------------------------------- -void rlSetClipPlanes(double near, double far) -{ - rlCullDistanceNear = near; - rlCullDistanceFar = far; -} - -double rlGetCullDistanceFar() -{ - return rlCullDistanceFar; -} - -double rlGetCullDistanceNear() -{ - return rlCullDistanceNear; -} - #if defined(GRAPHICS_API_OPENGL_11) // Fallback to OpenGL 1.1 function calls //--------------------------------------- @@ -1388,6 +1370,25 @@ void rlViewport(int x, int y, int width, int height) glViewport(x, y, width, height); } +// Set clip planes distances +void rlSetClipPlanes(double near, double far) +{ + rlCullDistanceNear = near; + rlCullDistanceFar = far; +} + +// Get cull plane distance near +double rlGetCullDistanceNear(void) +{ + return rlCullDistanceNear; +} + +// Get cull plane distance far +double rlGetCullDistanceFar(void) +{ + return rlCullDistanceFar; +} + //---------------------------------------------------------------------------------- // Module Functions Definition - Vertex level operations //---------------------------------------------------------------------------------- |
