cannontwo / cannon

Lifetime repository
https://cannontwo.com/cannon/
MIT License
0 stars 0 forks source link

Start Working on Raytracing Backend #67

Open cannontwo opened 3 years ago

cannontwo commented 3 years ago

Much like Blender's different display modes, it should be possible to switch between OpenGL pipeline rendering and raytracing. This could work by having the raytracer render into a buffer which is periodically swapped with a mutex-protected one that the OpenGL rendering thread can read, then draw to a ScreenQuad.

The most crucial part of this issue, however, is that the raytracing code and the pipeline rendering code should use the same classes and similar interfaces to geometry, lighting, etc. This will help to bring the pipeline renderer's behavior closer to the physically-based raytracer.

Also, the graphics directory needs to be restructured to have better encapsulation.

cannontwo commented 3 years ago

https://raytracing.github.io/

cannontwo commented 3 years ago

Currently at start of section 4.8

cannontwo commented 3 years ago

Finished book 1, starting book 2.

cannontwo commented 3 years ago

Finished book 2, now on book 3. Pausing for a little bit to clean up and optimize some code first.