summaryrefslogtreecommitdiffhomepage
path: root/examples/shaders/shaders_custom_uniform.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/shaders/shaders_custom_uniform.c')
-rw-r--r--examples/shaders/shaders_custom_uniform.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/examples/shaders/shaders_custom_uniform.c b/examples/shaders/shaders_custom_uniform.c
index a0f6fd22..4e160455 100644
--- a/examples/shaders/shaders_custom_uniform.c
+++ b/examples/shaders/shaders_custom_uniform.c
@@ -30,7 +30,12 @@ int main()
InitWindow(screenWidth, screenHeight, "raylib [shaders] example - custom uniform variable");
// Define the camera to look into our 3d world
- Camera camera = {{ 3.0f, 3.0f, 3.0f }, { 0.0f, 1.5f, 0.0f }, { 0.0f, 1.0f, 0.0f }, 45.0f };
+ Camera camera = { 0 };
+ camera.position = (Vector3){ 3.0f, 3.0f, 3.0f };
+ camera.target = (Vector3){ 0.0f, 1.5f, 0.0f };
+ camera.up = (Vector3){ 0.0f, 1.0f, 0.0f };
+ camera.fovy = 45.0f;
+ camera.type = CAMERA_PERSPECTIVE;
Model dwarf = LoadModel("resources/model/dwarf.obj"); // Load OBJ model
Texture2D texture = LoadTexture("resources/model/dwarf_diffuse.png"); // Load model texture (diffuse map)