PLUG'N SCRIPT
rapid plugin development
Tutorial
DSP
KUIML
How-to
Scripts
Main functions
  • processBlock
  • processSample
  • updateInputParameters
  • updateInputParametersForBlock
  • computeOutputData
Additional
  • initialize
  • shutdown
  • reset
  • getTailSize
  • getLatency
  • wantSilence
DSPreset
June 23, 2020

Reset

This function is used to "reset" state of a filter, clear buffers, etc. Say, you have some buffered data, that you work with, and suddenly it becomes obsolete: the sample rate has changed or buffer size, etc. 

  1. // the measured level
  2. double level=0;
  3.  
  4. void reset() {
  5. level=0; // reset level to zero
  6. }

As Blue Cat Audio said: "Reset is called when the host needs to reset the state of the plug-in. Typically before restarting playback from another location or after initialization. But it depends on the host application."

In my experience, it's called right after "initialize" when the script is loaded, when sample rate or buffer size has changed.

2020 - 2025 © Site by LetiMix  |  Plug'n Script and KUIML by Blue Cat Audio