feat(studio): bake WebAudio synth into offline audio tracks for Codex Tetris#870
Closed
miguel-heygen wants to merge 1 commit into
Closed
feat(studio): bake WebAudio synth into offline audio tracks for Codex Tetris#870miguel-heygen wants to merge 1 commit into
miguel-heygen wants to merge 1 commit into
Conversation
WebAudio synth (oscillators, noise channels) can't be captured by the headless renderer — it only picks up file-based <audio> tracks via FFmpeg. This composition demonstrates the fix: a bake-audio.ts script pre-renders chiptune BGM and SFX offline into WAV files using square/ triangle wave math, then the composition references them as standard <audio> elements with data-start/data-duration/data-volume attributes. Composition: 1080×1920 vertical, 28s, 4 scenes — QR scan → console boot → Tetris gameplay (Penrose cursor AI, line clears, score counter) → game over + attribution. Glitch + chromatic aberration transitions.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
<audio>tracks via FFmpeg during the audio stagebake-audio.tsthat pre-renders chiptune BGM and SFX offline into WAV files using square/triangle wave oscillator math — no external deps, justbun run bake-audio.ts<audio>elements withdata-start/data-duration/data-volume, so the producer pipeline picks them up normallyComposition
1080×1920 vertical, 28s, 4 scenes:
Transitions: glitch (primary, 2×) + chromatic aberration (accent, 1×)
Test plan
bun run bake-audio.tsgenerates valid bgm.wav and sfx.wav (28s PCM WAV each)npx hyperframes lintpasses with 0 errorsnpx hyperframes validate --no-contrastpasses with no console errors