6/9/2026 at 5:50:40 PM
Great article. I particularly enjoyed the approach to creating gibs. Although it was a tech demo, I created something like this around the mid 90s. One thing I did that I don't see mentioned in this article was I used 8x8 (or 16x16) light maps on the textures, which allowed me to easily have things like flickering torches and rockets that lit up the hallways as they shot down them. Lightmaps can also be used to "bake in" lighting if desired. Since the light map is "only" 8x8 you can afford to do some math on each luxel (each unit in the light map) to calculate distance and line of sight to light sources to determine a brightness value. When rendering the texture, the luxel was used with a lookup table to determine the actual color of the pixel being drawn. The light maps were updated 15 times a second if I recall correctly to help performance. Thanks to DJGPP, I was using inline assembly for the rendering. Since floating point math was slow at the time I used fixed point math which optimized well. The rendering was surprisingly performant on computers of the day.by Teslazar
6/9/2026 at 6:14:47 PM
> I used fixed point math which optimized well.I feel like the idea of fixed-point is under-utilized and very under appreciated. There are loads of applications where this is a better choice, let alone more performant.
by pragma_x
6/9/2026 at 7:05:47 PM
This was the choice that Knuth made in TeX and Metafont although it’s also at least in part because floating point implementations in the late 70s/early 80s were so inconsistent from one platform to the next that using native floating point couldn’t satisfy his requirement of identical output on all platforms (likewise, the variations of Pascal implementations meant that he also used a highly restricted subset of Pascal features and no dynamic memory allocation).by dhosek