Live data from Hacker News

Software rendering in 500 lines of bare C++

haqr.eu

81–83 of 83 posts

Re: Software rendering in 500 lines of bare C++

#81
post #45

on the topic of software rendering, im surprised how little gustavo pezzi's lectures get mentioned here on hacker news.

Gustavo's lectures are great! I work through his Compiler lectures now and I bought the 3D renderer course too.

Glad to hear that! All the topics are incredibly fun to play around with.

Re: Software rendering in 500 lines of bare C++

#82

Earlier quoted context omitted.

You do often need a graphics context to create the surface that displays the framebuffer.

Not necessarily. Most desktop OS compositors provide a void** buffer that can be blitted to. Sure, this buffer will probably end up going through the compositor which does GPU hardware acceleration anyway, but it is definitely possible to shrink the application-side stack without relying on D2D/GLUT/GLEW/GLFW/SDL/WGPU in this case. On Windows: CreateDIBSection and BitBlt On macOS: CALayer and CATransaction commit Not…

Handling platform-specific details like isn't really the fun part of writing a CPU renderer, IMO.
Post reply on HN