diff options
author | omniscient <17525998+omnisci3nce@users.noreply.github.com> | 2024-07-21 20:50:24 +1000 |
---|---|---|
committer | omniscient <17525998+omnisci3nce@users.noreply.github.com> | 2024-07-21 20:50:24 +1000 |
commit | da1ddc29ac15e511086b8b5343b735a34be1fcea (patch) | |
tree | 900d7b423b39eb350608fc75fa451736fb2c9b66 | |
parent | af79d7428895413eb64bcb640e07ebb26b1c19f3 (diff) |
increase view distance
-rw-r--r-- | assets/shaders/terrain.vert | 2 | ||||
-rw-r--r-- | src/core/camera.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/assets/shaders/terrain.vert b/assets/shaders/terrain.vert index 32b43b3..d21cbe6 100644 --- a/assets/shaders/terrain.vert +++ b/assets/shaders/terrain.vert @@ -13,5 +13,5 @@ out vec4 Color; void main() { gl_Position = cam.proj * cam.view * vec4(inPosition, 1.0); - Color = vec4(inPosition.y / 255.0); + Color = vec4(inPosition.y / 126.0); }
\ No newline at end of file diff --git a/src/core/camera.c b/src/core/camera.c index e3e812c..cde457b 100644 --- a/src/core/camera.c +++ b/src/core/camera.c @@ -10,7 +10,7 @@ Camera Camera_Create(Vec3 pos, Vec3 front, Vec3 up, f32 fov) { } Mat4 Camera_ViewProj(Camera *c, f32 lens_height, f32 lens_width, Mat4 *out_view, Mat4 *out_proj) { - Mat4 proj = mat4_perspective(c->fov, lens_width / lens_height, 0.1, 100.0); + Mat4 proj = mat4_perspective(c->fov, lens_width / lens_height, 0.1, 1000.0); Vec3 camera_direction = vec3_add(c->position, c->front); Mat4 view = mat4_look_at(c->position, camera_direction, c->up); if (out_view) { |