TECHNOLOGY

Four classic DOS demoscene productions now run in the browser from recompiled original code

A project called demoscene-recomp lets people play Future Crew's Unreal and Second Reality, Triton's Crystal Dream 2 and NoooN's Stars: Wonders of the World in a web browser. It says the original DOS code is recompiled instruction for instruction, with only the hardware modelled.

Browser window showing a retro VGA-style demoscene graphic on a monitor with a desk and keyboard nearbyTECHNOLOGY

Image: demoscene

A project called demoscene-recomp lets you play four classic PC demoscene productions in a web browser. A demo is a short program that shows off music, graphics and programming tricks.

The four demos are Unreal (v1.0) by Future Crew from 1992, Second Reality by Future Crew from 1993, Crystal Dream 2 by Triton from 1993, and Stars: Wonders of the World by NoooN from 1995. According to the project, all were released free to the demoscene. The original release files are served unmodified, as the demos read them at run time.

The project describes how it works in four steps. First, an x86 emulator, which is software that imitates an old PC processor, runs the demo and records every block of code the CPU actually executes. Second, that recording is translated into C, one instruction for one, keeping the exact cycle timing of the emulated machine.

Third, the C code is compiled to WebAssembly, a format that lets browsers run compiled programs. It is bundled with software models of the hardware the demo talks to: the timer, the VGA card and the Sound Blaster, an early PC sound card. Fourth, the result is checked against the emulator event for event. Every interrupt, port access and frame is meant to land at the same moment of emulated time.

The project says the demos' own loaders, music players and effects run as they did originally. Only the hardware is modelled. This article has not tested the demos, so that claim comes from the project's own description.

The demos ran on VGA at 70 Hz, meaning the picture updated 70 times a second. The project says they look smoothest on a display running at 70 Hz, or at 140 Hz or higher.

The demo pages have several options. A Section option lets you start from one of the demo's own start points. Fullscreen shows the picture at 4:3, as a VGA monitor displayed it. CRT Scanlines adds dark lines and slight softening to the picture, and turning it off gives the original picture.

There is also an optional enhancement for Second Reality called Smooth City. It interpolates the city flythrough camera animation to 70 frames per second and uses sub-pixel polygon edges. It is off by default, and off is the original.

Other controls include an interactive end menu in Crystal Dream 2, which uses the arrow keys and Enter. Tapping or clicking the picture pauses the demo. While paused, a camera button saves the frame as a PNG at the demo's own resolution. A menu at the top right switches the site style between Retro and Modern.

Sources and further readingdemoscene-recomp ↗
ABOUT THE DESK

Harsh DV

IntraGoals reports on important changes in technology and work. We check each story for clear writing, trusted sources and useful information before it is published.

KEEP READING

Latest from IntraGoals.

All latest stories ↗
Stack of poetry books including a red-covered volume on a desk beside a notebook and a windowPRODUCTIVITY

PRODUCTIVITY

Anne Carson wins 2026 Nobel Prize in Literature

The Swedish Academy has awarded the Nobel Prize in Literature to Canadian poet and essayist Anne Carson, citing work that plays with the classical tradition and creates new forms. The report comes via Hacker News, which links to a Guardian story.