Loading…
gathering yarn balls…
Cat Game Research
Frontier
Dev-log transmissions from the expedition

Crow Sign: A Game Built from Sine Waves

Zanzlanz's 'How I released a game that has no assets' walks through Crow Sign, an HTML5 game made entirely of sine waves. This companion guide maps the video's methods and proposes a new way to render CatGame levels: an oscilloscope-style renderer inside the existing Vulkan engine.

The premise

Zanzlanz's video "How I released a game that has no assets" is a love letter to the sine wave. The question is simple: can a video game ship with no image files, no audio files, and no font files — generating everything at runtime from sine waves? The answer, demonstrated through the HTML5 game Crow Sign, is yes. The game is not just small; it is structurally small, because its assets are formulas rather than bitstreams.

This companion guide maps the techniques the video calls out, relates them to the CatGame engine, and then sketches a different way to render a game level: an oscilloscope renderer that would fit inside the existing Vulkan render graph. All method names and numbers in the next sections are taken from the video narration and transcript; a few isolated phrases are hard to verify without the source code and are flagged in the caveats section at the end.

Watch the original video on YouTube

Why sine waves can be everything

The video starts with a single claim: any image, sound, or motion can be built by adding enough sine waves. In signal-processing terms this is Fourier synthesis — a signal is decomposed (or rebuilt) as a sum of sinusoids with different frequencies, amplitudes, and phases. The visual version is sometimes drawn as a chain of rotating circles: each circle is one harmonic, higher frequencies spin faster, and tracing the final circle's tip draws the target shape. This is exact for periodic signals and can approximate many shapes in two dimensions, but the video's "any image" is best read as "any image that can be represented by a synthesizable set of sinusoids," not a universal guarantee for arbitrary bitmaps.

"If you combine the right set of these sine waves, you can create a square. Or a triangle. Or a duck."

Zanzlanz · "How I released a game that has no assets"

For game assets, the practical trick is to keep only the strongest harmonics. A planet becomes a low-frequency circle with a few higher-frequency bumps. A character becomes a small set of keyframe shapes, and the game morphs between them by interpolating the frequency coefficients, not the vertex positions. The video calls this morphing "fading between the frequencies that make up each keyframe." The main character, a crow, is a combination of these harmonic sets; rotating it to stand on the planet is done by changing the starting rotation of all harmonics, which the narrator dubs crotation (his own term, not a standard one).

Fourier / harmonic drawing
Planets, ducks, crows, and the airplane are all stored as harmonic coefficients. Changing phase rotates the shape; fading coefficients morphs it.
Crotation
A coined term for rotating a harmonic object by shifting the starting rotation of all its sine-wave components, so it stands on the planet and walks.
Hyperbolic tangent
The plane's HUD map and altimeter use tanh for an infinitely squished, M.C. Escher-like dial effect — and because tanh is built from sine and cosine, it still honors the theme.
Sine language
A cursive font built from 26 harmonic letters that connect between words and can be animated to wiggle or draw in and out. The video calls this encoding "sine language" — an in-project name, not an established technical term.

Audio and music from the same building block

The video notes that taking a recorded sound, running a Fourier Transform, and playing it back would be almost the same as shipping an MP3. So Crow Sign synthesizes sounds from scratch using Audio Worklets in the browser. Audio Worklets are a Web Audio API feature that let a web page run custom, low-latency sample-generation code on a dedicated audio thread, effectively turning the browser into a software synthesizer. The game uses them to generate waveform samples on demand rather than decoding them from a file. Walking, jumping, landing, the plane engine, and popping balloons are all synthesized from basic waveforms (sine, triangle, square, noise) with envelopes and pitch sweeps.

Music is generated the same way. The video claims the music is over 500 times smaller than looped MP3s, because it is stored as note/sequence data plus a small synthesizer rather than as compressed audio samples. This is the same trade-off tracked music (MOD, XM, S3M) made in the 1990s, but rebuilt with modern Web Audio primitives.

The JPEG wormhole and DCT

One of the most visually striking effects is a real-time JPEG compression shader used in the wormhole scene. The video describes it as: each block of pixels is converted to cosine waves using the Discrete Cosine Transform (DCT), and more and more of those frequency coefficients are discarded closer to the wormhole center. That is the quantization step of JPEG compression; a full JPEG encoder also adds color-space conversion and entropy coding, so the shader is using the DCT/quantization look rather than the complete file-format pipeline. The narrator connects this to the "bubbly sound" and ripple patterns you see in over-compressed MP3s and JPEGs.

A note on the DCT/JPEG shader
DCT is a transform; JPEG is a pipeline. The video describes the effect as a real-time DCT/quantization shader, but does not show the exact implementation (block size, color space, quantization matrix, entropy coding). I am treating the description as the author's stated intent, not as an independent verification of the exact shader.

The numbers the video reports

At the end of the video, the narrator gives a set of file-size comparisons for Crow Sign. These are internally relative numbers from the project, not absolute industry benchmarks, but they show the magnitude of the savings.

Asset typeSine approachReported baselineSavings
FontHarmonic cursiveSimilar TrueType~0.5×
SpritesHarmonic shapesSVG or PNG~0.5× vs. SVG; ~1/7 vs. PNG
Sound effectsSynthesizedMP3~37×; ~6.5× without NPC voice variations
MusicGenerated loopsMP3 loops~500×
Total gameAll of the aboveEquivalent with assets~11× smaller; 455 KB
455 KB
Total Game Size
11×
Smaller vs Assets
500×
Music Savings
37×
SFX Savings

These are silly comparisons in the narrator's own words — no one expects AAA games to shrink with sine waves — but they are a useful proof of what can happen when every asset is a tiny formula instead of a compressed file.

How this connects to the CatGame engine

The CatGame engine is built around a different scale and target: a C++20 Vulkan engine with a RenderGraph, deferred and forward passes, bindless textures, and ComputePipeline support. But the underlying idea is the same: keep the source data small and let the GPU turn it into pixels. We already do that in several places.

The difference is mostly where the formulas live and what they produce. Crow Sign generates 2D vector art and audio in JavaScript and Web Audio. The CatGame engine can generate 3D geometry, particles, and full-screen post-processes in Vulkan compute and fragment shaders. The conceptual bridge is: data small, math big, output at runtime.

Concept: an oscilloscope renderer for CatGame levels

Here is a different way to render a game level that reuses the existing engine but adopts Crow Sign's "math as asset" philosophy. Instead of rasterizing shaded meshes, the OscilloscopeRenderPass treats the visible scene as a single continuous waveform and draws it the way an oscilloscope draws a signal: a bright electron beam tracing vector paths across a dark screen, with phosphor persistence and deflection blanking.

A naive trace of every edge would draw hidden lines on top of visible ones, so the pass needs a visibility strategy. The simplest option is to read the existing depth buffer and only emit trace samples for fragments that pass a depth test, giving an oscilloscope projection of the visible 3D surface. The stylized option is to ignore occlusion entirely and accept the "X-ray" wireframe look. The depth-aware version is closer to a real oscilloscope drawing a physical object; the non-depth version is closer to a vector-art style.

LEVEL GEOMETRYtile grid + entitiesFOURIER TRACEharmonic pathVECTOR BUFFER(x,y,blank) listCRT OUTPUTpersistence + glowA single continuous trace, not a shaded triangle mesh

How it would plug into the existing engine

The render graph in engine/systems/render/graph/render_graph_presets.cpp already orders passes: shadow, primitive, vmesh, outline, vfx, debug lines, text. A new OscilloscopeRenderPass would be inserted after the world passes and before UI, or it could be a post-process that reads the GBuffer/depth and emits a trace image. Two implementation paths are possible:

01
Collect. Read the level tile grid (already a flat uint16_t buffer) and the visible entity list from the camera cull pass. For each visible surface edge, emit a world-space line segment. This is conceptually a compute shader dispatch over tiles, similar to how VFX fills its SSBO.
↓
02
Convert to trace. Sort and concatenate the line segments into a continuous (or near-continuous) beam path. Add blanking jumps — (x, y, 0) flags — where the beam should move without drawing. The output is a structured buffer of (position, blank, intensity) tuples, not a triangle list.
↓
03
Fourier or epicycloid option. For a Crow Sign-style twist, each line segment could be represented by a short harmonic sequence. A compute shader solves for the amplitudes and phases that draw the path, then the GPU steps the path as a sequence of rotating-vector additions. This is more expensive but true to the video's theme.
↓
04
Render as CRT. A fragment shader expands each trace sample into a glowing point with a Gaussian falloff, then a second pass simulates phosphor persistence and horizontal scan-line retrace. The final image is a dark-field vector display of the level, not a lit 3D scene.

Where the existing code fits

Status: concept, not implemented
The OscilloscopeRenderPass described here is a design concept. It is not on the current main branch, not in the render graph, and has no associated compute shader. It is intended as a roadmap exploration and a possible VFX/debug tool, not a shipped feature.

Mentions beyond the main pipeline

Other named mechanisms in the video

The video also mentions 32 animated harmonics for the airplane propeller and body; two circles for landing wheels; a speedometer, altimeter, and map as the plane HUD; and Audio Worklets as the browser audio thread primitive. The source of these details is the video's narration and auto-generated transcript; some proper names (e.g., crotation, sine language) are the narrator's own terms and should be treated as in-project coinages, not established technical terms.

Caveats and limitations

Closing thought

Crow Sign is a useful reminder that "assets" can mean formulas. The CatGame engine already leans in that direction for tiles, particles, and compute effects. The oscilloscope renderer concept is one way to push the same idea into the renderer itself: a level drawn not by rasterizing triangles, but by tracing a mathematical path. Whether it ships as a debug visualization, an Easter-egg render mode, or a full level style, it is the kind of experiment that fits a project trying to keep data small and math visible.

← All transmissions