diff --git a/src/shader/depth_shader.c b/src/shader/depth_shader.c
index 1facff6..907cef7 100644
--- a/src/shader/depth_shader.c
+++ b/src/shader/depth_shader.c
@@ -1,5 +1,7 @@
 #include "depth_shader.h"
+#include "constants.h"
 #include "shader.h"
+#include "utils.h"
 
 VertexData depth_shader_vertex(void *shader, const VertexData *vert, u8 index, const Model *model) {
   DepthShader *shdr = (DepthShader *)shader;
@@ -20,7 +22,8 @@ FragmentResult depth_shader_fragment(void *shader, const V3f *barycentric, const
   pos_mat       = mat3x3_transpose(pos_mat);
   V3f position  = mat3x3_mul_vec3(pos_mat, (*barycentric));
 
-  V4f output = {.r = position.z, .g = position.z, .b = position.z, .a = 255};
+  f32 channel = clamp(position.z + DEPTH_MAX, 0.0f, DEPTH_MAX);
+  V4f output = {.r = channel, .g = channel, .b = channel, .a = 255};
 
   return (FragmentResult){.colour = output};
 }