From 090f91787b3f4e4711e4aada5ffc232d984b8ce1 Mon Sep 17 00:00:00 2001 From: 3gg <3gg@shellblade.net> Date: Tue, 13 Feb 2024 18:26:47 -0800 Subject: Adjust camera field of view. --- game/src/plugins/viewer.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/game/src/plugins/viewer.c b/game/src/plugins/viewer.c index 1ed3b9d..3000b30 100644 --- a/game/src/plugins/viewer.c +++ b/game/src/plugins/viewer.c @@ -119,6 +119,7 @@ bool init(Game* game, State** pp_state) { if (!node) { goto cleanup; } + Anima* anima = gfx_get_node_anima(node); gfx_play_animation( anima, &(AnimationPlaySettings){.name = "Walk", .loop = true}); @@ -159,7 +160,7 @@ void update(Game* game, State* state, double t, double dt) { Camera* camera = gfx_get_camera_camera(state->camera); spatial3_orbit( &camera->spatial, orbit_point, - /*radius=*/2.5, + /*radius=*/5, /*azimuth=*/t * 0.5, /*zenith=*/0); spatial3_lookat(&camera->spatial, orbit_point); } @@ -246,7 +247,7 @@ void resize(Game* game, State* state, int width, int height) { assert(game); assert(state); - const R fovy = 90 * TO_RAD; + const R fovy = 60 * TO_RAD; const R aspect = (R)width / (R)height; const R near = 0.1; const R far = 1000; -- cgit v1.2.3