mirror of
https://github.com/raysan5/raylib.git
synced 2025-09-23 03:28:30 +00:00
Updated lighting system...
...to avoid dynamic conditions on for loop (lightsCount) on standard shader, it seems GLSL 100 doesn't support that feature... on some GPUs like RaspberryPi...
This commit is contained in:
@@ -218,9 +218,9 @@ typedef enum { OPENGL_11 = 1, OPENGL_21, OPENGL_33, OPENGL_ES_20 } GlVersion;
|
||||
// Light type
|
||||
typedef struct LightData {
|
||||
unsigned int id; // Light unique id
|
||||
int type; // Light type: LIGHT_POINT, LIGHT_DIRECTIONAL, LIGHT_SPOT
|
||||
bool enabled; // Light enabled
|
||||
|
||||
int type; // Light type: LIGHT_POINT, LIGHT_DIRECTIONAL, LIGHT_SPOT
|
||||
|
||||
Vector3 position; // Light position
|
||||
Vector3 target; // Light target: LIGHT_DIRECTIONAL and LIGHT_SPOT (cone direction target)
|
||||
float radius; // Light attenuation radius light intensity reduced with distance (world distance)
|
||||
|
Reference in New Issue
Block a user