chore: land janitor round 1 and graft integration

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
This commit is contained in:
biggy committed 2026-10-06 08:50:45 +02:00
1 parent 5c942cad0c
commit e4cea300db
63 files changed
+2360 -805

No files matched your search

+13 -4
View File
@@ -1,4 +1,5 @@
#include "Oscillator.h"
#include "ExactCompare.h"
namespace serum
{
@@ -12,9 +13,8 @@ void Oscillator::reset()
paramsValid = false;
}
void Oscillator::noteOn (double freqHz, const OscParams& p, juce::uint32 seed)
void Oscillator::noteOn (const OscParams& p, juce::uint32 seed)
{
jassert (freqHz > 0.0);
rng.setSeed (seed);
initializedUnison = 0;
paramsValid = false;
@@ -25,8 +25,9 @@ void Oscillator::setParams (const OscParams& p) noexcept
{
const int uni = juce::jlimit (1, kMaxUnison, p.unison);
const bool countChanged = ! paramsValid || uni != activeUnison;
const bool detuneChanged = countChanged || p.detune != cachedParams.detune;
const bool panChanged = countChanged || p.pan != cachedParams.pan || p.spread != cachedParams.spread;
const bool detuneChanged = countChanged || changed (p.detune, cachedParams.detune);
const bool panChanged = countChanged || changed (p.pan, cachedParams.pan)
|| changed (p.spread, cachedParams.spread);
if (! detuneChanged && ! panChanged)
return;
@@ -98,6 +99,7 @@ float Oscillator::warpPhase (float phase, const OscParams& p) const noexcept
}
case WarpMode::PWM: return phase;
case WarpMode::Fold: return phase;
case WarpMode::Count: return phase;
default: return phase;
}
}
@@ -114,6 +116,13 @@ float Oscillator::warpSample (float sample, const OscParams& p) const noexcept
}
case WarpMode::Fold:
return std::sin (sample * (1.0f + amt * 5.0f) * 1.5707963267948966f);
case WarpMode::None:
case WarpMode::BendPlus:
case WarpMode::BendMinus:
case WarpMode::Sync:
case WarpMode::Asym:
case WarpMode::Mirror:
case WarpMode::Count:
default:
return sample;
}