Use INFINITY for nearest_t
This commit is contained in:
parent
a644539fd3
commit
ca2a5c1b3b
1 changed files with 1 additions and 1 deletions
|
@ -145,7 +145,7 @@ scene_trace_ray(Scene *scene, const Ray ray, const int depth)
|
||||||
// Find intersections of this ray with objects in the scene.
|
// Find intersections of this ray with objects in the scene.
|
||||||
Object *intersected_obj = NULL;
|
Object *intersected_obj = NULL;
|
||||||
float *t = NULL;
|
float *t = NULL;
|
||||||
float nearest_t = 1e8;
|
float nearest_t = INFINITY;
|
||||||
int nints;
|
int nints;
|
||||||
ObjectList *ptr = scene->objects;
|
ObjectList *ptr = scene->objects;
|
||||||
while (ptr != NULL) {
|
while (ptr != NULL) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue