SynthLab SDK
|
This is the "blank" core template for compiling your own Cores as dynamic modules. More...
#include <synthlabcore.h>
Public Member Functions | |
SynthLabCore () | |
Construction: Cores follow the same construction pattern. More... | |
virtual bool | reset (CoreProcData &processInfo) override |
Resets object to initialized state. More... | |
virtual bool | update (CoreProcData &processInfo) override |
Updates the object for the next block of audio processing. More... | |
virtual bool | render (CoreProcData &processInfo) override |
Renders the output of the module. More... | |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
Note-on handler for the ModuleCore. More... | |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
Note-off handler for the ModuleCore. More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
virtual int32_t | getState () override |
virtual bool | shutdown () override |
Shutdown handler for EG. More... | |
virtual void | setSustainOverride (bool b) override |
Sustain pedal handler for EG. More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
void | flushDelays () |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
double | renderSample (SynthClock &clock, double shape=0.5) |
Renders one sample out of the wavetable Core Specific: More... | |
double | renderHardSyncSample (SynthClock &clock, double shape=0.5) |
Renders one hard-synced sample from the wavetable Core Specific: More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
virtual int32_t | getState () override |
virtual bool | shutdown () override |
virtual void | setSustainOverride (bool b) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
double | renderSample (SynthClock &clock, double shape=0.5) |
double | renderHardSyncSample (SynthClock &clock, double shape) |
bool | createTables (double sampleRate=44100.0) |
Table Creation funciont. More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
virtual int32_t | getState () override |
virtual bool | shutdown () override |
virtual void | setSustainOverride (bool b) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
double | renderSample (SynthClock &clock) |
render a sample More... | |
double | renderHardSyncSample (SynthClock &clock) |
render a hard-sunk sample More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
double | renderSample (SynthClock &clock, bool forceLoop) |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
double | renderSawtoothSample (SynthClock &clock, bool advanceClock=true) |
BLEP sawtooth. More... | |
double | renderSquareSample (SynthClock &clock, double &sawtoothSample) |
sum of saws method More... | |
SynthLabCore () | |
virtual | ~SynthLabCore () |
virtual bool | reset (CoreProcData &processInfo) override |
virtual bool | update (CoreProcData &processInfo) override |
virtual bool | render (CoreProcData &processInfo) override |
virtual bool | doNoteOn (CoreProcData &processInfo) override |
virtual bool | doNoteOff (CoreProcData &processInfo) override |
Public Member Functions inherited from SynthLab::ModuleCore | |
ModuleCore () | |
Constructs a ModuleCore. More... | |
virtual void | setStandAloneMode (bool b) |
bool | startGlideModulation (GlideInfo &glideInfo) |
uint32_t | getModuleType () |
const char * | getModuleName () |
void * | getModuleHandle () |
void | setModuleHandle (void *handle) |
uint32_t | getModuleIndex () |
void | setModuleIndex (uint32_t index) |
int32_t | getPreferredModuleIndex () |
void | setPreferredModuleIndex (uint32_t index) |
ModuleCoreData & | getModuleData () |
provides access to the core data: More... | |
Protected Types | |
enum | { a0, a1, a2, b1, b2, c0, d0 } |
enum | { kNylonGtr, kDistGtr, kBass, kSilent } |
Protected Member Functions | |
void | calcAttackCoeff (double attackTime, double attackTimeScalar=1.0) |
void | calcDecayCoeff (double decayTime, double decayTimeScalar=1.0) |
void | calcReleaseCoeff (double releaseTime, double releaseTimeScalar=1.0) |
void | checkAddWavetable (SynthLabTableSet &slTableSet, CoreProcData &processInfo, uint32_t waveIndex) |
helper function to check database for wavetable and add it if the table does not exist More... | |
double | renderSample (SynthClock &clock, bool forceLoop) |
Renders one sample out of the wavetable Core Specific: More... | |
double | setStepInc (double timeMsec, double scale=1.0) |
Calculates linear step increment based on time in millisecs. More... | |
void | checkAddSampleSet (std::string sampleDirectory, std::string sampleName, CoreProcData &processInfo, uint32_t index) |
Query the PCM database and add sample sources as needed. More... | |
double | setStepInc (double timeMsec, double scale=1.0) |
void | checkAddSampleSet (std::string sampleDirectory, std::string sampleName, CoreProcData &processInfo, uint32_t index) |
query and add a sample set to the database | |
void | addMorphBankData (std::string name, SynthLabBankSet &slTableSet, uint32_t index) |
add a bank top database More... | |
void | checkAddWaveBank (SynthLabBankSet &slTableSet, CoreProcData &processInfo, uint32_t waveIndex) |
Calls the querying function to check and add a new wavebank (set of wavetables) More... | |
int32_t | checkAddWavetable (SynthLabTableSet &slTableSet, StaticTableSource *tableSource, CoreProcData &processInfo) |
Function that queries the datbase for the various tables based on unique table names. More... | |
void | checkAddSampleSet (std::string sampleDirectory, std::string sampleName, CoreProcData &processInfo, uint32_t index) |
Protected Attributes | |
double | sampleRate = 1.0 |
sample rate More... | |
bool | noteOff = false |
for retriggering EG More... | |
bool | retriggered = false |
for retriggering EG More... | |
double | lastTriggerMod = 0.0 |
for retriggering EG trigger detection More... | |
double | sustainLevel = 1.0 |
level, not time | |
double | attackTime_mSec = 1.0 |
att: is a time duration | |
double | decayTime_mSec = 1.0 |
dcy: is a time to decay from max output to 0.0 | |
double | releaseTime_mSec = 1.0 |
rel: is a time to decay from max output to 0.0 | |
double | envelopeOutput = 0.0 |
the current envelope output sample More... | |
double | attackCoeff = 0.0 |
exponential feedback coefficient | |
double | attackOffset = 0.0 |
TCO offset to allow proper attack/decay on [1, 0]. | |
double | attackTCO = 0.0 |
TCO value for calculating offset. | |
double | decayCoeff = 0.0 |
exponential feedback coefficient | |
double | decayOffset = 0.0 |
TCO offset to allow proper attack/decay on [1, 0]. | |
double | decayTCO = 0.0 |
TCO value for calculating offset. | |
double | releaseCoeff = 0.0 |
exponential feedback coefficient | |
double | releaseOffset = 0.0 |
TCO offset to allow proper attack/decay on [1, 0]. | |
double | releaseTCO = 0.0 |
TCO value for calculating offset. | |
bool | sustainOverride = false |
if true, places the EG into sustain mode | |
bool | releasePending = false |
a flag set when a note off event occurs while the sustain pedal is held, telling the EG to go to the release state once the pedal is released | |
double | incShutdown = 0.0 |
shutdown linear incrementer | |
EGState | state = EGState::kOff |
EG state variable. More... | |
BQAudioFilter | filter [STEREO_CHANNELS] |
biquad audio filter objects | |
double | outputAmp = 1.0 |
output scaling More... | |
double | midiPitch = 440.0 |
midi note pitch More... | |
std::unique_ptr< BasicLookupTables > | lookupTables = nullptr |
LUTs for some waveforms. | |
double | outputValue = 0.0 |
current output, More... | |
double | rshOutputValue = 0.0 |
current output, | |
SynthClock | lfoClock |
timbase | |
bool | renderComplete = false |
flag for one-shot | |
NoiseGenerator | noiseGen |
for noise based LFOs | |
Timer | sampleHoldTimer |
for sample and hold waveforms | |
Timer | delayTimer |
LFO turn on delay. | |
RampModulator | fadeInModulator |
LFO fade-in modulator. | |
double | outputAmplitude = 1.0 |
amplitude in dB | |
double | panLeftGain = 0.707 |
left channel gain | |
double | panRightGain = 0.707 |
right channel gain | |
int32_t | currentWaveIndex = -1 |
to minimize dictionary (map) lookup iterating | |
SynthClock | oscClock |
the oscillator timebase More... | |
IWavetableSource * | selectedTableSource = nullptr |
selected table More... | |
Synchronizer | hardSyncronizer |
hard sync helper More... | |
StaticTableSource | wavetables [MODULE_STRINGS] |
bool | oneShotDone = false |
one-shot flag More... | |
DrumWTSource | drumTables [MODULE_STRINGS] |
double | egStepInc = 0.0 |
linear time stepping More... | |
double | attackTimeScalar = 0.0 |
for MIDI modulations to attack time More... | |
double | decayTimeScalar = 0.0 |
for MIDI modulations to decay time More... | |
double | linearEnvOutput = 0.0 |
current outupt | |
double | curveEnvOutput = 0.0 |
current outupt | |
double | dxOutput = 0.0 |
final output value | |
double | releaseLevel = 0.0 |
release end point | |
bool | resetToZero = false |
notes the EG is in reset-to-zero mode | |
double | modStrength = 1.0 |
current output, | |
SynthClock | fmOpClock [NUM_FMLFO_OPS] |
for 3 operators | |
SineTableSource | sineTableSource |
a single sinewave table More... | |
std::unique_ptr< DXEG > | dxEG = nullptr |
an EG for FM modulation | |
std::shared_ptr< EGParameters > | dxEGParameters = nullptr |
EG parameters for controlling the EG. | |
double | currentTableRate = 0.0 |
sample rate | |
double | hardSyncRatio = 1.0 |
for hard sync More... | |
DynamicTableSource | dynamicTableSource |
dynamic tables come out of this source | |
uint32_t | pluckPosition = 1 |
position: 0 = at nut, 1 = at center of string | |
double | saturation = 1.0 |
for distortion control | |
Exciter | exciter |
exciter for KS model | |
Resonator | resonator |
resonator for KS model | |
HighShelfFilter | highShelfFilter |
filter for adding bite to exciter | |
LP2Filter | bassFilter |
for bass guitar pickup simulation | |
LP2Filter | distortionFilter |
for soft clip distortion | |
PluckPosFilter | pluckPosFilter |
for simulating pluck position with comb filter | |
ParametricFilter | bodyFilter |
sinple parameteric filter for adding a resonant hump to th output More... | |
double | readIndex = 0.0 |
must persist between update and render More... | |
double | phaseInc = 0.0 |
must persist between update and render More... | |
uint32_t | currentIndex = 0 |
must persist between update and render More... | |
IPCMSampleSource * | selectedSampleSource = nullptr |
current PCM sample More... | |
SynthLabPCMSource | pcmSources [MODULE_STRINGS] |
int32_t | currentTable0 = -1 |
to minimize dictionary (map) lookup iterating | |
int32_t | currentTable1 = -1 |
to minimize dictionary (map) lookup iterating | |
double | mixValue0 = 0.0 |
double | mixValue1 = 0.0 |
MorphBankData | morphBankData [MODULE_STRINGS] |
morphing bank of wavetables | |
int32_t | table0last = -1 |
running index of last table_0 | |
int32_t | table1last = -1 |
running index of last table_1 | |
double | morphLocation = 0.0 |
fractional location to morph between table_0 and table_1 | |
double | lastMorphMod = -10.0 |
last morph modulator | |
DrumWTSource | sfxTables [MODULE_STRINGS] |
pitchless wavetable sets | |
VA1Filter | va1 [STEREO] |
1st order VA | |
VASVFilter | svf [STEREO] |
SVF. | |
VAKorg35Filter | korg35 [STEREO] |
Korg35. | |
VAMoogFilter | moog [STEREO] |
moog | |
VADiodeFilter | diode [STEREO] |
diode | |
FilterModel | selectedModel = FilterModel::kFirstOrder |
uint32_t | outputIndex = 0 |
selected output | |
bool | forceDualMonoFilters = false |
DM option for slow machines. | |
Limiter | limiter [STEREO] |
limiters to squelch oscillations | |
double | pulseWidth = 0.5 |
[0.5, 0.95] for square wave only | |
Protected Attributes inherited from SynthLab::ModuleCore | |
uint32_t | moduleType = UNDEFINED_MODULE |
type of module, LFO_MODULE, EG_MODULE, etc... | |
const char * | moduleName = nullptr |
module name must be set in derived constructor | |
void * | moduleHandle = nullptr |
used for dynamically loading cores from DLLs | |
uint32_t | moduleIndex = 0 |
index of this core | |
int32_t | preferredIndex = -1 |
preferred index of this DYNAMIC core | |
ModuleCoreData | coreData |
core strings (16) and mod knob labels (4) | |
bool | standAloneMode = false |
flag for stand-alone mode of operation outside of SynthLab | |
std::unique_ptr< GlideModulator > | glideModulator |
built-in glide modulator for oscillators | |
This is the "blank" core template for compiling your own Cores as dynamic modules.
PCM oscillator that plays wave-slices that are mapped to the C-major scale keys starting at middle C.
Virtual Analog oscillator implementation.
Implements all of the virtual analog (VA) filters in the Synth Book using sub-filtering objects.
Wavetable oscillator with one-shot sound-effects (SFX) extracted into wavetables from WAV files.
Morphing Wavetable oscillator.
PCM oscillator using Mellotron(R) samples freely available.
Simplest EG of all, using linear segments - the place to start to build your own EG from scratch.
PCM oscillator using the same multi-samples from the 1st edition of the Synth Book.
Implements three Karplus-Strong algorithms to generate.
Fourier wavetable oscillator with sine and parabola waveforms.
Sinusoidal-only oscillator and attached EG.
LFO using simple FM algorithms for interesting modulators.
Yamaha DX EG-based.
Wavetables that implement electronic drum samples; these samples were extracted from WAV files and converted into wavetables using RackAFX-TableMaker.
Wavetable oscillator with classic waveforms.
LFO that renders all classical and many noisy wavforms.
Implements Filters via BiQuad structures; includes one pole HPF and LPF.
Analog EG emulator.
Base Class: ModuleCore
GUI Parameters: Depends on the type of Core you are implementing
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Render:
Base Class: ModuleCore
GUI Parameters: EGParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: FilterParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: LFOParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: WTOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
This is one of the simplest wavetable oscillator cores because the samples are pitchless and there is no pitch modulation applied. Pitch modulation addition is an excellent homework chore.
Base Class: ModuleCore
GUI Parameters: WTOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: EGParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: LFOParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: FMOperatorParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: WTOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: KSOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: PCMOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: EGParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: PCMOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: WTOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Base Class: ModuleCore
GUI Parameters: WTOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Demonstrates use of following VAFilter objects:
Base Class: ModuleCore
GUI Parameters: FilterParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
This object outputs both square, saw, or a blend of these two; great for TB303 emulation or Oberheim SEM
Base Class: ModuleCore
GUI Parameters: VAOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
Used Aubio tools to generate the slice WAV files, but may be done with any app.
Base Class: ModuleCore
GUI Parameters: PCMOscParameters
Access to Modulators is done via the thunk-barrier compliant CoreProcData argument
Access to audio buffers (I/O/FM) is done via the thunk-barrier compliant CoreProcData argument
Construction: Cores follow the same construction pattern
Standalone Mode:
Module Strings, zero-indexed for your GUI Control:
ModKnob Strings, for fixed GUI controls by index constant
Render:
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
Construction: Cores follow the same construction pattern.
Constructs Construction: Cores follow the same construction pattern.
Constructs FM oscillator Core including standalone DXEG object.
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Construction: Cores follow the same construction pattern
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
Core Specific:
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
SynthLab::SynthLabCore::SynthLabCore | ( | ) |
simple default constructor
|
inlinevirtual |
Destructor is empty: all resources are smart pointers
|
protected |
add a bank top database
Adds a set of tables to the morph bank data structures, storing names of the tables.
Core Specific:
name | name of wavetable |
slBankSet | set of sets-of-tables to be added |
index | index in MorphBankData structure |
|
inlineprotected |
Calculate Time Coefficients
|
inlineprotected |
Calculate Time Coefficients
|
inlineprotected |
Calculate Time Coefficients
|
protected |
Query the PCM database and add sample sources as needed.
Query the database and add a set of PCM samples if not existing already.
sampleDirectory | dirctory full of PCM WAV files ]param sampleName name of this sample set to check |
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
sampleDirectory | folder full of folders of samples |
sampleName | name of sub-folder with set of PCM samples |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
|
protected |
Calls the querying function to check and add a new wavebank (set of wavetables)
slBankSet | set of banks to be added |
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
waveIndex | index of module-string array corresponding to this set |
|
protected |
helper function to check database for wavetable and add it if the table does not exist
Core Specific:
slTableSet | a set of wavetables for a single waveform |
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
waveIndex | index of the module-string that corresponds to this table; used for fast lookup |
|
protected |
Function that queries the datbase for the various tables based on unique table names.
slTableSet | set of tables tp be added |
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
bool SynthLab::SynthLabCore::createTables | ( | double | sampleRate = 44100.0 | ) |
Table Creation funciont.
Dynamic table creation, based on fx
sampleRate | required for bandlimiting operation |
|
overridevirtual |
Note-off handler for the ModuleCore.
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Implements SynthLab::ModuleCore.
|
overridevirtual |
Note-on handler for the ModuleCore.
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
Implements SynthLab::ModuleCore.
|
inline |
flush biquad delays on reset and new note events
|
inlineoverridevirtual |
ModuleCore Overrides for EG Cores only
Reimplemented from SynthLab::ModuleCore.
|
inlineoverridevirtual |
ModuleCore Overrides for EG Cores only
Reimplemented from SynthLab::ModuleCore.
|
inlineoverridevirtual |
ModuleCore Overrides for EG Cores only
Reimplemented from SynthLab::ModuleCore.
|
overridevirtual |
Renders the output of the module.
Renders one block of audio data Core Specific:
Core Specific:
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | is the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
< current outupt
< current outupt
Implements SynthLab::ModuleCore.
double SynthLab::SynthLabCore::renderHardSyncSample | ( | SynthClock & | clock, |
double | shape = 0.5 |
||
) |
Renders one hard-synced sample from the wavetable Core Specific:
clock | the current timebase |
shape | the shape amount [-1, +1] from GUI and/or modulation |
double SynthLab::SynthLabCore::renderHardSyncSample | ( | SynthClock & | clock | ) |
render a hard-sunk sample
Renders one hard-synced sample from the wavetable Core Specific:
clock | the current timebase |
double SynthLab::SynthLabCore::renderSample | ( | SynthClock & | clock, |
bool | forceLoop | ||
) |
Helper function for rendering
double SynthLab::SynthLabCore::renderSample | ( | SynthClock & | clock, |
double | shape = 0.5 |
||
) |
Helper functions for rendering
double SynthLab::SynthLabCore::renderSample | ( | SynthClock & | clock, |
double | shape = 0.5 |
||
) |
Renders one sample out of the wavetable Core Specific:
Helper functions for rendering
clock | the current timebase |
shape | the shape amount [-1, +1] from GUI and/or modulation |
|
protected |
Renders one sample out of the wavetable Core Specific:
helper to render each sample from wavetable
clock | the current timebase |
clock | the current timebase |
forceLoop | true to force this sample to loop (repeated over duration) |
double SynthLab::SynthLabCore::renderSample | ( | SynthClock & | clock | ) |
render a sample
Renders one sample out of the wavetable Core Specific:
Render helper functions
clock | the current timebase |
double SynthLab::SynthLabCore::renderSawtoothSample | ( | SynthClock & | clock, |
bool | advanceClock = true |
||
) |
BLEP sawtooth.
Renders a BLEP sawtooth sample Core Specific:
helper to render each sample
clock | the current timebase |
advanceClock | true to advance clock after render |
double SynthLab::SynthLabCore::renderSquareSample | ( | SynthClock & | clock, |
double & | sawtoothSample | ||
) |
sum of saws method
Renders a BLEP squarewave sample with sum-of-saws methog Core Specific:
clock | the current timebase |
|
overridevirtual |
Resets object to initialized state.
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
overridevirtual |
ModuleCore Overrides
Implements SynthLab::ModuleCore.
|
inlineprotected |
Calculates linear step increment based on time in millisecs.
calculate new step size
timeMsec | the time in milliseconds scalar value for stretching or shrinking the final value |
|
inlineprotected |
calculate new step size
|
overridevirtual |
Sustain pedal handler for EG.
Reimplemented from SynthLab::ModuleCore.
|
overridevirtual |
Shutdown handler for EG.
Reimplemented from SynthLab::ModuleCore.
|
overridevirtual |
Updates the object for the next block of audio processing.
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
Uses three simple stacked FM algorithms: kFM2
kFM3A
kFM3B
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
Core Specific:
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
processInfo | the thunk-barrier compliant data structure for passing all needed parameters |
Implements SynthLab::ModuleCore.
|
protected |
for MIDI modulations to attack time
for MIDI modulation
|
protected |
sinple parameteric filter for adding a resonant hump to th output
simple enumeration for model choice
|
protected |
must persist between update and render
must persist from update to render
index of sample; does not change often
|
protected |
for MIDI modulations to decay time
for MIDI modulation
|
protected |
linear time stepping
current stepping inc
local variables
|
protected |
the current envelope output sample
current output
current outupt
|
protected |
for hard sync
hard sync ratio with modulators applied
|
protected |
hard sync helper
hard synchronizer
|
protected |
for retriggering EG trigger detection
for detecting rising edge of modulator
|
protected |
midi note pitch
key tracking
the midi pitch
|
protected |
for retriggering EG
not currently used
|
protected |
one-shot flag
one shot flag
|
protected |
the oscillator timebase
timebase
|
protected |
output scaling
filter output amplitude, tweked from GUI in dB
|
protected |
current output,
last output value needed for self Feedback
|
protected |
must persist between update and render
must persist from update to render
need to persist from update to render
|
protected |
must persist between update and render
must persist from update to render
need to persist from update to render
|
protected |
for retriggering EG
for retrigger modulation
|
protected |
sample rate
fs
|
protected |
current PCM sample
selected PCM sample
PCM sourse database object.
|
protected |
selected table
two tables to morph across
selected dynamic table
selected based on oscillator pitch
|
protected |
a single sinewave table
sine table for very high frequney notes that have only one harmonic (the fundamental)
|
protected |
EG state variable.
FSM state variable.
state variable for FSM