For anyone interested in an accessible introduction to the (simple) math and algorithms behind this kind of software rasterizer, I present <a href="https://gabrielgambetta.com/computer-graphics-from-scratch" rel="nofollow">https://gabrielgambetta.com/computer-graphics-from-scratch</a> (soon to become an actual book, thanks to the positive reception it has had in Hacker News!)