MCPcopy Create free account
hub / github.com/jerryuhoo/Fire / timerCallback

Method timerCallback

Source/Panels/SpectrogramPanel/FilterControl.cpp:221–240  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

219}
220
221void FilterControl::timerCallback()
222{
223 // The core of the optimization
224 // If no LFO is modulating the filter, this function does nothing.
225 if (! isAnimationActive)
226 return;
227
228 ModulatedFilterValues modulatedValues;
229
230 // Safely pull the latest data packet from the FIFO queue.
231 if (processor.getLatestModulatedFilterValues(modulatedValues))
232 {
233 // If we got new data, update the LFO chain and its response curve.
234 updateLfoChain(modulatedValues);
235 updateLfoResponseCurve();
236
237 // Trigger a repaint to show the changes on screen.
238 repaint();
239 }
240}
241
242// This callback responds to preset loads or other global changes
243void FilterControl::changeListenerCallback(juce::ChangeBroadcaster* source)

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected