Morozov-5F / raytracing-weekend

Simple path rendered written in modern C. Based on first book from https://github.com/RayTracing/raytracing.github.io
BSD 3-Clause "New" or "Revised" License
20 stars 0 forks source link

Figure out the rotation bug #4

Closed Morozov-5F closed 2 years ago

Morozov-5F commented 3 years ago

For some reason if we rotate the cube for more than 45 degrees all kind of weird stuff happen -- some of the cube side becomes shaded, while others don't. Easiest way to reproduce the issue is change the "instance test" scene so the cube is rotated for more than 45 degrees.

Morozov-5F commented 3 years ago

The issue also reproduces on polygonal models from #5. It feels like it has something to do with the normal vector pointing inside the surface.

Morozov-5F commented 2 years ago

This is probably due to a possible bug in the reference implementation: https://github.com/RayTracing/raytracing.github.io/issues/965