Attempting to fix ray-tracing