Ray Tracer ported to an x86 boot sector in only 483 bytes, run on Pentium Pro and faster CPUs

 Nanochess' Boot Sector Ray Tracer Demo.
Nanochess' Boot Sector Ray Tracer Demo.

Do you think real-time ray tracing requires a modern GPU? It still does for practical applications, but YouTuber nanochess has a functioning ray tracing demo with ray-traced reflections working on machines as old as an original Intel Pentium Pro (1995), and in only  *483 bytes at that. Below, we've embedded the original video of this demo, titled Boot Sector Ray Tracer.

*Previously 506. Changed during the writing of this article!

Boot Sector Ray Tracer is a simple demo showcasing a camera coming across two reflective orbs floating in the air in the middle of a large, empty space surrounded by a colorful sky. The colors of the sky reflect off of both orbs realistically, as do the reflections of the orbs themselves, resulting in a hall-of-mirrors effect if one looks into the correct part of the reflection during the animation. It's also real-time animation, so the final speed will depend on your hardware.

The main ray tracing effect being shown is ray traced reflections. Non-ray traced graphics, or rasterized graphics usually, can only display reflections based on information already available onscreen. These limitations have workarounds like rendering additional character models in video games, but there's no room for "workarounds" in 483 bytes!

The full demo is available for free on GitHub and is recommended to those who have the old hardware lying around or don't mind setting up a virtual machine for something like this. The YouTube animation runs on a Macbook Air through a VirtualBox'd Windows XP, and seems to run perfectly smoothly despite the virtual machine ahead.

Other projects by Nanochess include an Intel 8080 emulator, various Chess programs, and even various homebrew games for retro consoles and PCs (Intellivision, MSX, Atari, etc).

Additionally, Boot Sector Ray Tracer is inspired by a similar 8-bit "RayTrace Movie" demo released for Atari, though that runs at frames-per-hour. The visual touching up that this (relatively) more modern Boot Sector RT demo makes it look more akin to something like the classic Amiga ball demo instead of the pure-pixel vaporwave aesthetic of the original Atari demo.