85 float tick(fl::u32 nowMs,
float manualSpeedScalar);
102 float driveSilence(fl::u32 nowMs,
float manualSpeedScalar);
fl::Animartrix animartrix(xyMap, FIRST_ANIMATION)
SoundState classify(fl::u32 nowMs)
float tick(fl::u32 nowMs, float manualSpeedScalar)
Per-frame tick.
void begin()
Wire up audio callbacks (downbeat/kick/snare).
float driveBpmLocked(fl::u32 nowMs, float manualSpeedScalar)
float lastEngineSpeed() const
static fl::AnimartrixAnim pickAnimationFor(SoundState s, fl::u32 nowMs)
SoundOrchestrator(fl::shared_ptr< fl::audio::Processor > processor, fl::shared_ptr< fl::Animartrix > animartrix, fl::FxEngine *engine)
const OrchestratorConfig & config() const
void switchAnimationIfNeeded(SoundState newState, fl::u32 nowMs)
fl::AnimartrixAnim mCurrentAnim
fl::u32 stateEnteredAtMs() const
fl::u32 mCandidateSinceMs
float driveSilence(fl::u32 nowMs, float manualSpeedScalar)
float driveDisorganized(fl::u32 nowMs, float manualSpeedScalar)
SoundState state() const
Observability.
fl::u32 mNonSilentSinceMs
fl::shared_ptr< fl::audio::Processor > mProcessor
fl::shared_ptr< fl::Animartrix > mAnimartrix
fl::u32 mStateEnteredAtMs
void setConfig(const OrchestratorConfig &cfg)
Override config (e.g. from UI sliders). Cheap; safe to call every tick.
Manages and renders multiple visual effects (Fx) for LED strips.
const char * toString(SoundState s)
fl::u32 classifierHysteresisMs
float tempoConfidenceExit
leave BpmLocked when tempoConf < this
fl::u32 silenceExitMs
sound must persist this long to leave Silence
float disorganizedSpeedSpan
float beatConfidenceEnter
also require beatConf >= this for BpmLocked
fl::u32 silenceEnterMs
silence must persist this long to enter Silence
float tempoConfidenceEnter
enter BpmLocked when tempoConf >= this