International Edition
Latest News
Technology

SQLDoom Renders Full-Color Doom Using SQL Database Queries

Lukas Vogel Renders Doom Inside CedarDB Database Using SQL Queries Software engineer Lukas Vogel has successfully rendered the classic video game Doom inside a relational database, utilizing a small Python client and CedarDB to generate 35 full-color frames…

SQLDoom Renders Full-Color Doom Using SQL Database Queries

Lukas Vogel Renders Doom Inside CedarDB Database Using SQL Queries

Software engineer Lukas Vogel has successfully rendered the classic video game Doom inside a relational database, utilizing a small Python client and CedarDB to generate 35 full-color frames per second. The updated project, known as SQLDoom, uses a Python client to handle user input, manage game timing, and display frames. Behind this interface, a series of CedarDB tables tracks game geometry and state. Approximately 1,300 lines of SQL queries spread across 89 common table expressions execute the game logic to produce 640×480 resolution graphics.

Converting WAD Files and Optimizing Performance with SQL Queries

Converting the original game assets into a relational format was straightforward because id Software structured Doom levels around distinct components like vertices, lines, and sectors. Vogel explained in a blog post that even the game’s binary-space partition trees translate effectively into SQL by assigning a pre-computed `sort_key` to objects at load time.

With this sorting key established in the database tables, a simple `ORDER BY` statement determines which wall segments to display and which to omit during each frame refresh. This method dramatically improves rendering performance compared to previous database gaming experiments, allowing the software to output color frames that closely resemble the original executable.

Technical Specifications of the SQLDoom Engine

* Framerate: 35 frames per second
* Resolution: 640×480 pixels
* Database Management System: CedarDB
* Code Volume: ~1,300 lines of SQL across 89 common table expressions
* Input/Output Handling: Python client

Frequently Asked Questions About SQLDoom

What is the role of the Python client in SQLDoom?

The Python client manages external tasks that fall outside the database engine’s core capabilities. It handles player input, drives game timing, and renders each processed frame onto the screen.

How does SQLDoom differ from the previous DoomQL project?

While DoomQL relied on raycasting and grayscale ASCII graphics that resembled early 1990s title screens, SQLDoom produces full-color 640×480 framebuffers that mirror the visual output of the original game executable.

Why did Lukas Vogel undertake this project?

Vogel acknowledged the unorthodox nature of the experiment, writing that rendering Doom in a database is “obviously a bad idea,” yet pursued it to test the limits of relational database performance and query execution.

About the author: Anika Shah - Technology

MSc in Computer Science, senior reporter. Anika focuses on AI ethics, cybersecurity, and emerging hardware—frequently moderating panels at CES and Web Summit. “Anika Shah decodes tech breakthroughs and startup disruption shaping tomorrow’s digital landscape.”