summaryrefslogtreecommitdiffhomepage
path: root/examples/models/models_billboard.c
diff options
context:
space:
mode:
Diffstat (limited to 'examples/models/models_billboard.c')
-rw-r--r--examples/models/models_billboard.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/examples/models/models_billboard.c b/examples/models/models_billboard.c
index 59655714..597e9a60 100644
--- a/examples/models/models_billboard.c
+++ b/examples/models/models_billboard.c
@@ -11,12 +11,12 @@
#include "raylib.h"
-int main()
+int main(void)
{
// Initialization
//--------------------------------------------------------------------------------------
- int screenWidth = 800;
- int screenHeight = 450;
+ const int screenWidth = 800;
+ const int screenHeight = 450;
InitWindow(screenWidth, screenHeight, "raylib [models] example - drawing billboards");
@@ -27,10 +27,10 @@ int main()
camera.up = (Vector3){ 0.0f, 1.0f, 0.0f };
camera.fovy = 45.0f;
camera.type = CAMERA_PERSPECTIVE;
-
+
Texture2D bill = LoadTexture("resources/billboard.png"); // Our texture billboard
Vector3 billPosition = { 0.0f, 2.0f, 0.0f }; // Position where draw billboard
-
+
SetCameraMode(camera, CAMERA_ORBITAL); // Set an orbital camera mode
SetTargetFPS(60); // Set our game to run at 60 frames-per-second
@@ -51,11 +51,11 @@ int main()
ClearBackground(RAYWHITE);
BeginMode3D(camera);
-
+
DrawGrid(10, 1.0f); // Draw a grid
-
+
DrawBillboard(camera, bill, billPosition, 2.0f, WHITE);
-
+
EndMode3D();
DrawFPS(10, 10);