Programmer installed and ran Doom on an orbiting European Space Agency satellite

Earth from Space
(Image credit: Getty Images)

There were lots of interesting topics discussed in the recent Ubuntu Summit, but one in particular might just tickle the fancy of most any techie above 30: the story of how Doom was actually running in space. Programmer Ólafur Waage recounted the tale of when his team took part in the European Space Agency's hacking challenge and got the seminal game running on a satellite.

The satellite in question was the now-decommissioned OPS-SAT "flying laboratory," whose sole purpose in life was to be a playground of sorts for improving "mission control and onboard satellite systems." It measured only 10 x 10 x 30 cm (3.94" x 3.94" x 11.81") and carried an onboard computer the ESA said was "10 times more powerful than any [ESA spacecraft at the time]".

Running DOOM on a satellite - YouTube Running DOOM on a satellite - YouTube
Watch On

Despite the relatively powerful computer compared to the 1992-era Intel 486 machines that originally ran Doom, the software environment was still limited. The team couldn't just upload every software dependency needed to build the game. Additionally, each hacking team had limited time slots to push and run code on the satellite, making attempts very precious and precluding any real-time input. This also meant that the team had to use Doom time demos of the first level.

Running Doom took two tries, with the first using Chocolate Doom, a source-faithful port that uses SDL as its graphics and sound backend, an OS-agnostic library with very few dependencies. It worked well enough, but it produced no graphical output, as the satellite didn't have a screen. And as Waage put it, even if it did, you'd need a really good telescope. At this point, all the team had was the final level text output with the percentage complete and enemies killed. It was nevertheless a good check that the code was running smoothly and unaffected by cosmic rays.

Since Waage and his imps wanted some graphical output, they pivoted to doomgeneric, a port of Doom designed to make porting to other systems easier. They then assigned graphical output to a virtual video card and took screenshots of the game. But then, how do you proudly display to the world that this particular Doom was in space? By using the satellite's camera images of Earth for the game's outdoor background, of course.

This clever idea came with a few problems of its own, as the really nice camera onboard the satellite produced images with far more resolution and bit depth than the game engine would take, so the team had to turn to an onboard AI model from another team that would resize and color-reduce the photographs to 8-bit files with relatively little color loss.

Even so, that wasn't quite enough, as Doom's 256-color palette is fixed and lacks many of the hues needed for the mostly blue, brown, and green images. Complex problems beget complex solutions, though, so the ultimate heresy was performed: slightly tweaking the game's color palette to better match the fancy background. It was as if suddenly a million geeks cried out in terror. We can only look forward to Doom actually running on Mars, where the game is set.

Google Preferred Source

Follow Tom's Hardware on Google News, or add us as a preferred source, to get our latest news, analysis, & reviews in your feeds.

Bruno Ferreira
Contributor

Bruno Ferreira is a contributing writer for Tom's Hardware. He has decades of experience with PC hardware and assorted sundries, alongside a career as a developer. He's obsessed with detail and has a tendency to ramble on the topics he loves. When not doing that, he's usually playing games, or at live music shows and festivals.