# 64k Demo Project ## Goal - Produce a <=64k native demo binary - Same C++ codebase for Windows, macOS, Linux ## Graphics - WebGPU via wgpu-native - WGSL shaders - Hybrid rendering: Rasterized proxy geometry + SDF raymarching ## Audio - 32 kHz, 16-bit stereo - Procedurally generated samples - Real-time additive synthesis from spectrograms (IDCT) - Variable tempo system with music time abstraction - Event-based pattern triggering for dynamic tempo scaling - Modifiable Loops and Patterns, w/ script to generate them (like a Tracker) - Unified AudioEngine for lifecycle management ## Constraints - Size-sensitive - Minimal dependencies - Explicit control over all allocations ## Style - Demoscene - No engine abstractions --- ## Current Status - **Workspace system:** Multi-workspace support. Easy switching with `-DDEMO_WORKSPACE=`. Shared common assets. - **Audio:** Sample-accurate sync. Zero heap allocations per frame. Variable tempo. Comprehensive tests. - **Shaders:** Parameterized effects (UniformHelper, .seq syntax). Modular WGSL composition. - **3D:** Hybrid SDF/rasterization with BVH. Binary scene loader. Blender pipeline. - **Build:** Asset dependency tracking. Size measurement. Hot-reload (debug-only). - **Testing:** **36/36 passing (100%)** --- ## Next Up See `TODO.md` for current priorities and active tasks. --- ## Documentation **Essential:** - `doc/ARCHITECTURE.md` - System architecture and design decisions - `doc/HOWTO.md` - Common operations and workflows - `doc/CONTRIBUTING.md` - Development protocols **Technical Reference:** - Core: `ASSET_SYSTEM.md`, `SEQUENCE.md`, `TRACKER.md`, `3D.md` - Formats: `SCENE_FORMAT.md`, `MASKING_SYSTEM.md` - Tools: `BUILD.md`, `WORKSPACE_SYSTEM.md`, `SIZE_MEASUREMENT.md` **History:** - `doc/COMPLETED.md` - Completed tasks archive - Git log for detailed change history