Let’s Code MS DOS 0x21: 3D Fixed Point Maths

The 3D Wireframe cube is part of every demoscene coder’s learning curve. Today I want to talk you through the principles of 3D programming in general and especially the idea of fixed point maths, where you use integers instead of floating point numbers to represent fractions. Older CPUs before the 80486 had no built in floating point support, and even the FPUs were quite often rather slow and hard to program for, if available at all. So people had to opt to use integer arithmetics in stead. But 3D graphics requires fractional numbers, so how do we get both things together and manage to display a rotating wireframe cube on our MS DOS machine?

Leave a Reply

Your email address will not be published.