Round 1 findings and fixes, all previously uncommitted: - FXProcessor per-slot DSP history repair (HEAD does not compile without it) - SynthVoice::getModulationValue, editor control-lock guard - ExactCompare.h naming the deliberate exact float comparisons - KnobLookAndFeel replacing the never-installed SerumLookAndFeel - 55 first-party compiler warnings to 0 - AGENT.md renamed to AGENTS.md across Source/ - graft repository context graph and its hooks - JANITOR_TASKS.md and UI_UX_AUDIT.md records
34 lines
949 B
Markdown
34 lines
949 B
Markdown
# presets module
|
|
|
|
## Owned files
|
|
|
|
- FactoryPresets.h
|
|
- FactoryPresets.cpp
|
|
|
|
## Rules
|
|
|
|
- Build presets as sparse maps; unset parameters keep their APVTS defaults.
|
|
- Use `ids::` for every parameter ID, never raw strings.
|
|
- Use named helpers (coarse, unison, slope, fx, lfoShape, mod) to build normalized values.
|
|
- Return the preset list as `const std::vector<FactoryPreset>&` from a static local.
|
|
- Reference `ModConnection` and macro assignment structs instead of ad hoc tuples.
|
|
|
|
## IF-THEN
|
|
|
|
- IF a preset omits a parameter THEN leave it at its default; do not write an explicit zero.
|
|
- IF a preset sets a physical value THEN encode it through the same `maps::` helpers the DSP uses.
|
|
|
|
## Examples
|
|
|
|
```cpp
|
|
// BAD: raw string ID and an opaque normalized number
|
|
pr.params = { { "oscAUnison", 0.4f } };
|
|
```
|
|
|
|
```cpp
|
|
// GOOD: ids:: and a named helper
|
|
pr.params = { p (ids::oscAUnison, unison (7)) };
|
|
```
|
|
|
|
This file overrides /AGENTS.md where they conflict.
|