summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modules/ray/ray_scene.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/ray/ray_scene.c b/src/modules/ray/ray_scene.c
index e44990b..496c447 100644
--- a/src/modules/ray/ray_scene.c
+++ b/src/modules/ray/ray_scene.c
@@ -107,7 +107,7 @@ static inline ray_color_t shade_ray(ray_scene_t *scene, ray_ray_t *ray, ray_obje
reflected_ray.origin = intersection;
reflected_ray.direction = ray_3f_sub(&ray->direction, &reflected_ray.direction);
- reflection = trace_ray(scene, &reflected_ray, depth + 1);
+ reflection = trace_ray(scene, &reflected_ray, depth);
reflection = ray_3f_mult_scalar(&reflection, surface.specular);
color = ray_3f_add(&color, &reflection);
#endif
© All Rights Reserved