Initialize nearest_t to 1e8

This commit is contained in:
Eryn Wells 2013-09-08 11:56:57 -07:00
parent d9d27e2d22
commit 4407f757e6

View file

@ -152,7 +152,7 @@ scene_trace_ray(Scene *scene, const Ray ray, const int depth)
// Find intersections of this ray with objects in the scene.
Object *intersected_obj = NULL;
float *t = NULL;
float nearest_t;
float nearest_t = 1e8;
int nints;
ObjectList *ptr = scene->objects;
while (ptr != NULL) {