How maujabur/laser-harp works
Harpa Laser is a browser-based laser-harp synthesizer. Players trigger notes by keyboard, touch/mouse, or MIDI; the app maps them to scale notes and voices, then synthesizes audio. Users can shape the sound and select, save, import, or export presets. The graph separates input, synthesis, controls, and preset/state handling. Most behavior lives in app.js; relationships not visible in the excerpts are included only where the README documents them.
Main entry points: app.js Preset Selector · presets Preset Collection · index.html Browser UI
Components 18
Note Input
- Keyboard and Touch
app.js - MIDI Input
app.js - Scale and Note Mapping
app.js
Audio Synthesis
- Polyphonic Harp
app.js - Laser Voice
app.js - Tone.js Audio
- Chorus and Output
app.js
Sound Controls
- Synth Controls
app.js - Volume Control
app.js - URL Configuration
app.js
Presets and State
- Preset Selector
app.js - Factory Presets
app.js - Preset Collection
presets - Saved Vibes
app.js - Import and Export
app.js
Other components
- Player
- Browser Storage
- Browser UI
index.html
Connections 22
- Player → Keyboard and Touch: plays notes
README.md - Keyboard and Touch → Scale and Note Mapping: maps key
README.md - Player → MIDI Input: sends MIDI
app.js - MIDI Input → Scale and Note Mapping: maps pitch
app.js - Scale and Note Mapping → Polyphonic Harp: triggers notes
README.md - Polyphonic Harp → Laser Voice: allocates voices
app.js - Laser Voice → Tone.js Audio: synthesizes audio
README.md - Laser Voice → Chorus and Output: routes audio
app.js - Player → Synth Controls: adjusts sound
README.md - Synth Controls → Polyphonic Harp: updates voices
app.js - Player → Volume Control: adjusts level
README.md - Player → URL Configuration: sets limits
README.md - URL Configuration → Polyphonic Harp: sets polyphony
README.md - Player → Preset Selector: selects vibe
README.md - Factory Presets → Preset Selector: offers presets
README.md - Preset Collection → Preset Selector: loads collection
README.md - Preset Selector → Polyphonic Harp: applies settings
README.md - Preset Selector → Saved Vibes: saves vibes
README.md - Saved Vibes → Browser Storage: persists settings
README.md - Player → Import and Export: imports or exports
README.md - Import and Export → Saved Vibes: adds imported vibe
README.md - Browser UI → Synth Controls: presents controls
README.md