MCPcopy Create free account
hub / github.com/DISTRHO/DPF / ExamplePluginMetronome

Function ExamplePluginMetronome

examples/Metronome/ExamplePluginMetronome.cpp:71–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69{
70public:
71 ExamplePluginMetronome()
72 : Plugin(4, 0, 0), // 4 parameters, 0 programs, 0 states
73 sampleRate(getSampleRate()),
74 counter(0),
75 wasPlaying(false),
76 phase(0.0f),
77 envelope(1.0f),
78 decay(0.0f),
79 gain(0.5f),
80 semitone(72),
81 cent(0),
82 decayTime(0.2f)
83 {
84 sampleRateChanged(sampleRate);
85 }
86
87protected:
88 /* --------------------------------------------------------------------------------------------------------

Callers

nothing calls this directly

Calls 2

sampleRateChangedFunction · 0.70
getSampleRateFunction · 0.50

Tested by

no test coverage detected