mirror of
https://github.com/anomalyco/hex.git
synced 2026-11-28 13:02:21 +01:00
| Filename | Latest commit message | Latest commit date |
|---|---|---|
Adds src/sound_synth.rs, a deterministic synth (pitch glide, raised-cosine attack, exponential decay, band-passed noise breath, low-pass, saturation, K-weighted loudness normalization) with six compiled recipes in resources/sounds/presets.json. The feedback loader renders them at startup alongside the bundled classic set, which stays the default. Settings gains a Sound picker next to Sound volume that previews the start tone. prototypes/sound-synth/synth.js is the reference implementation behind the tuning prototype; tests compare Rust renders against its exported fixtures and check onset, length, clipping, loudness and spectral centroid. |
||
| .. | ||
| index.html | ||
| main.js | ||
| README.md | ||
| render.ts | ||
| style.css | ||
| synth.js | ||
Sound synth
synth.js is the reference implementation of Hex's procedural feedback tones;
src/sound_synth.rs mirrors it step for step. Recipes live in
resources/sounds/presets.json; the tuner's "Copy preset" output is one entry.
bun prototypes/sound-synth/render.tsrewritestests/fixtures/sound_synthafter a change to the algorithm or the presets (the Rust parity test reads it).bun prototypes/sound-synth/render.ts <dir>also writes WAVs for offline checks.
The tuner page (index.html, main.js) runs on the Problems viewer kit. To
publish it, stage a folder with these files plus kit/ (copied from the
team-board repo), presets.js (export default + presets.json) and
sounds/classic/{start,stop,cancel}.mp3, then board.ts publish <dir> --include sounds.