From 6ff226f4faff5fdd9c73fdbe60f9887811cebbec Mon Sep 17 00:00:00 2001 From: Nathan Vegdahl Date: Wed, 25 Oct 2017 07:09:16 -0700 Subject: [PATCH] Whoops, nope. The last commit was a mistake. It *seemed* to fix the problem I was running into, but it actually made the SphereLight ray intersection code incorrect, and wa just avoiding intersections that should have happened. I should test better before committing. :-) --- src/light/sphere_light.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/light/sphere_light.rs b/src/light/sphere_light.rs index 4a2334e..afeea9a 100644 --- a/src/light/sphere_light.rs +++ b/src/light/sphere_light.rs @@ -227,7 +227,7 @@ impl<'a> Surface for SphereLight<'a> { let radius = lerp_slice(self.radii, r.time); // Radius of the sphere // Get the ray origin and direction in local space - let orig = (r.orig * xform).into_vector(); + let orig = r.orig.into_vector(); let dir = wr.dir * xform; // Code adapted to Rust from https://github.com/Tecla/Rayito