WARNING: BREAKING: RENAMED: camera.type to camera.projection

This commit is contained in:
Ray
2021-03-19 13:56:46 +01:00
parent d4e2c331b1
commit 07d82a91c5
20 changed files with 32 additions and 32 deletions

View File

@ -40,15 +40,15 @@ int main(void)
//----------------------------------------------------------------------------------
if (IsKeyPressed(KEY_SPACE))
{
if (camera.type == CAMERA_PERSPECTIVE)
if (camera.projection == CAMERA_PERSPECTIVE)
{
camera.fovy = WIDTH_ORTHOGRAPHIC;
camera.type = CAMERA_ORTHOGRAPHIC;
camera.projection = CAMERA_ORTHOGRAPHIC;
}
else
{
camera.fovy = FOVY_PERSPECTIVE;
camera.type = CAMERA_PERSPECTIVE;
camera.projection = CAMERA_PERSPECTIVE;
}
}
//----------------------------------------------------------------------------------
@ -81,8 +81,8 @@ int main(void)
DrawText("Press Spacebar to switch camera type", 10, GetScreenHeight() - 30, 20, DARKGRAY);
if (camera.type == CAMERA_ORTHOGRAPHIC) DrawText("ORTHOGRAPHIC", 10, 40, 20, BLACK);
else if (camera.type == CAMERA_PERSPECTIVE) DrawText("PERSPECTIVE", 10, 40, 20, BLACK);
if (camera.projection == CAMERA_ORTHOGRAPHIC) DrawText("ORTHOGRAPHIC", 10, 40, 20, BLACK);
else if (camera.projection == CAMERA_PERSPECTIVE) DrawText("PERSPECTIVE", 10, 40, 20, BLACK);
DrawFPS(10, 10);