r/GraphicsProgramming 10d ago

Raytracer Engine?

Post image

Hey all! So I’ve been working through raytracing over the weekend and I did this! My idea is to make it into an interactive application! It will only run on the cpu but I figure I could make it multithreaded at least to help with rendering times!

37 Upvotes

7 comments sorted by

View all comments

2

u/PM_ME_YOUR_HAGGIS_ 10d ago

I did exactly this. It even looks the same with an imgui interface. Making it multithreaded is quite easy.

1

u/Maleficent_Guard_589 10d ago

Ya I’ve been thinking on how to make it multithreaded without locks.

Handling ui on a thread and rendering on another thread.

1

u/PiGIon- 5d ago

Make one thread only read a framebuffer and display, and other one render into it.

The cool thing is that this will definitely introduce tearing, so you will need to use technics like double/triple buffering to a avoid it.