SynthLab SDK
vaoscillator.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include "synthbase.h"
4 #include "synthfunctions.h"
5 #include "vaocore.h"
6 
7 // -----------------------------
8 // --- SynthLab SDK File --- //
9 // ----------------------------
17 // -----------------------------------------------------------------------------
18 namespace SynthLab
19 {
104  class VAOscillator : public SynthModule
105  {
106  public:
108  VAOscillator(std::shared_ptr<MidiInputData> _midiInputData,
109  std::shared_ptr<VAOscParameters> _parameters,
110  uint32_t blockSize = 32);
111 
113  virtual ~VAOscillator() {}/* D-TOR */
114 
116  virtual bool reset(double _sampleRate) override;
117  virtual bool update() override;
118  virtual bool render(uint32_t samplesToProcess = 1) override;
119  virtual bool doNoteOn(MIDINoteEvent& noteEvent) override;
120  virtual bool doNoteOff(MIDINoteEvent& noteEvent) override;
121 
123  std::shared_ptr<VAOscParameters> getParameters() { return parameters; }
124 
125  protected:
127  std::shared_ptr<VAOscParameters> parameters = nullptr;
128  };
129 
130 
131 }
virtual ~VAOscillator()
Definition: vaoscillator.h:113
std::shared_ptr< VAOscParameters > parameters
Definition: vaoscillator.h:127
virtual bool doNoteOff(MIDINoteEvent &noteEvent) override
Calls the note-off handler for all cores.
Definition: vaoscillator.cpp:135
std::shared_ptr< VAOscParameters > getParameters()
Definition: vaoscillator.h:123
See also Designing Software Synthesizers in C++ 2nd Ed. by Will Pirkle.
Definition: addosccore.cpp:4
virtual bool update() override
Updates the selected core; sets GLOBAL engine variable unisonDetuneCents that may have changed since ...
Definition: vaoscillator.cpp:87
virtual bool doNoteOn(MIDINoteEvent &noteEvent) override
Calls the note-on handler for all cores.
Definition: vaoscillator.cpp:118
Virtual analog oscillator module.
Definition: vaoscillator.h:104
Abstract base class that encapsulates functionality of a module; used with the Module-Core paradigm...
Definition: synthbase.h:1600
VAOscillator(std::shared_ptr< MidiInputData > _midiInputData, std::shared_ptr< VAOscParameters > _parameters, uint32_t blockSize=32)
Constructs Virtual Analog Oscillator module.
Definition: vaoscillator.cpp:27
hard-coded arrays of FIR filter coefficients for the sample rate conversion objects (Interpolator and...
virtual bool reset(double _sampleRate) override
Resets object to initialized state.
Definition: vaoscillator.cpp:67
Information about a MIDI note event (note on or note off).
Definition: synthstructures.h:212
See also Designing Software Synthesizers in C++ 2nd Ed. by Will Pirkle.
virtual bool render(uint32_t samplesToProcess=1) override
Renders audio from the selected core.
Definition: vaoscillator.cpp:104