Expand narrated story, preserve solved patterns, and add ambience

Connect the island story with new character memories and narrative transitions.
Blend each solved symbol into its artwork and retain a replayable pattern stamp.
Allow completed grids to be inspected after navigation and app restarts.
Reduce campaign difficulty spikes and keep explained story hints free.

Append 24 narrated continuations while preserving original PCM takes. Add
four offline environmental loops with saved mute/volume controls, scene
fades, narration ducking and lifecycle handling.

Validation: 31 unit/widget tests, Flutter analysis, narration and soundscape
asset checks, tablet discovery layouts and extended-audio integration,
including simultaneous active voice and ambience mixer tracks.
This commit is contained in:
Hadrian Burkhardt
2026-11-02 05:04:57 +01:00
parent 6bd14a9e20
commit 68871ec573
102 changed files with 2322 additions and 520 deletions
+5 -3
View File
@@ -1,8 +1,8 @@
# Bundled diary readings and guiding narration
Twenty-eight fixed recordings accompany the story. Mara’s five original diary readings use `bf_emma` (British female); twenty-three guiding passages use a distinct `bm_george` narrator (British male). These are **synthetic recordings rendered during development**, not human voice-actor recordings. The app plays bundled files through just_audio, with no speech model, Android reader, runtime synthesis or download. Mara’s original WAV masters remain unchanged.
Twenty-eight fixed recordings accompany the story. Mara’s five original diary readings use `bf_emma` (British female); twenty-three guiding passages use a distinct `bm_george` narrator (British male). These are **synthetic recordings rendered during development**, not human voice-actor recordings. The app plays bundled files through just_audio, with no speech model, Android reader, runtime synthesis or download. The original PCM takes remain unchanged as prefixes of the expanded masters. Twenty-four recordings now append the complete new story passages in the narrator voice; the other four recordings remain unchanged.
- `scripts.json`: canonical scripts with stable IDs, speaker, voice and rendering speed. Narrator passages match notebook entry/memory/closing text or the later campaign before/after passages.
- `scripts.json`: canonical scripts with stable IDs, speaker, voice and rendering speed. Each complete script matches the displayed original text plus its continuation. Expanded records retain `baseText`, `continuation` and `continuationSpeaker`; the renderer records the original frame count and PCM checksum. The window and match memory keep Mara’s diary take, then switch to the narrator for the added present-day action.
- `wav/`: reviewable 24 kHz mono PCM16 WAV masters.
- `manifest.json`: model/voice checksums, generator versions, exact scripts, passage timings and WAV and FLAC checksums.
- `assets/audio/narration_*.wav`: bundled PCM16 copies, byte-identical to the WAV masters.
@@ -19,6 +19,8 @@ Use Python 3.12, dependencies pinned in `requirements.txt` and ffmpeg. Keep mode
```sh
python scripts/render_narration.py --model /path/to/kokoro-v1.0.onnx --voices /path/to/voices-v1.0.bin
# Append new narrator passages while preserving existing PCM takes:
python scripts/render_narration.py --model /path/to/kokoro-v1.0.onnx --voices /path/to/voices-v1.0.bin --append-continuations
python3 scripts/check_narration_assets.py
# Regenerate only guiding narration, preserving Mara’s existing takes:
@@ -32,4 +34,4 @@ A future actor recording can replace the masters and bundled assets while preser
Playback uses PCM WAV because the connected Huawei API 26 tablet advanced the FLAC clock without creating an AudioTrack. WAV produces an active, unmuted 24 kHz mono PCM media track through the speaker, and the user confirmed audible speech. The release smoke test now checks that mixer track, in addition to pause/resume and elapsed time.
The seven cottage narrator recordings cover the lantern/key/compass entries and memories and the closing threshold leaf. Sixteen more cover the before/after passages for campaign levels 4–11. Puzzle instruction leaves remain unvoiced. On-screen labels distinguish “Mara · diary reading” from “Narrator · recorded story”; playback is opt-in and stops on navigation or backgrounding. Cue highlighting follows the exact displayed passage.
The seven cottage narrator recordings cover the lantern/key/compass entries and memories and the closing threshold leaf. Sixteen more cover the before/after passages for campaign levels 4–11. Puzzle instruction leaves remain unvoiced. On-screen labels distinguish “Mara · diary reading” from “Narrator · recorded story”; playback is opt-in and stops on navigation or backgrounding. Cue highlighting follows both displayed passages. One Play/Pause/Resume/Replay control covers the whole page, and the speaker label follows per-cue voice changes. Original PCM-prefix hashes are checked alongside full-track checksums.