OpenWareLaboratory
WavetableOscillator Class Reference
Inheritance diagram for WavetableOscillator:
Collaboration diagram for WavetableOscillator:

Public Member Functions

virtual float getNextSample (float fm)
 
float getNextSample ()
 
float getSample (float phase)
 
virtual void getSamples (FloatArray output, FloatArray fm)
 
void getSamples (FloatArray samples)
 
virtual void reset ()
 
void setFrequency (float freq)
 
void setSampleRate (float value)
 
 WavetableOscillator (float sr, const FloatArray wavetable)
 

Static Public Member Functions

static WavetableOscillatorcreate (float sr, size_t size)
 
static void destroy (WavetableOscillator *osc)
 

Detailed Description

Definition at line 7 of file WavetableOscillator.h.

Constructor & Destructor Documentation

WavetableOscillator::WavetableOscillator ( float  sr,
const FloatArray  wavetable 
)

Definition at line 17 of file WavetableOscillator.cpp.

Referenced by create().

Member Function Documentation

WavetableOscillator * WavetableOscillator::create ( float  sr,
size_t  size 
)
static

Definition at line 5 of file WavetableOscillator.cpp.

References FloatArray::create(), M_PI, and WavetableOscillator().

void WavetableOscillator::destroy ( WavetableOscillator osc)
static

Definition at line 12 of file WavetableOscillator.cpp.

References FloatArray::destroy().

virtual float Oscillator::getNextSample ( float  fm)
inlinevirtualinherited

Reimplemented in RampOscillator, and SineOscillator.

Definition at line 11 of file Oscillator.h.

float WavetableOscillator::getNextSample ( )
virtual

Reimplemented from Oscillator.

Definition at line 39 of file WavetableOscillator.cpp.

References getSample().

Referenced by getSamples().

float WavetableOscillator::getSample ( float  phase)

Definition at line 32 of file WavetableOscillator.cpp.

References FloatArray::getSize(), and min.

Referenced by getNextSample().

virtual void Oscillator::getSamples ( FloatArray  output,
FloatArray  fm 
)
inlinevirtualinherited

Reimplemented in PolyBlepOscillator.

Definition at line 17 of file Oscillator.h.

References Oscillator::getNextSample(), and FloatArray::getSize().

void WavetableOscillator::getSamples ( FloatArray  samples)
virtual

Reimplemented from Oscillator.

Definition at line 47 of file WavetableOscillator.cpp.

References getNextSample(), and FloatArray::getSize().

virtual void Oscillator::reset ( )
inlinevirtualinherited

Reimplemented in RampOscillator, and SineOscillator.

Definition at line 23 of file Oscillator.h.

void WavetableOscillator::setFrequency ( float  freq)
virtual

Reimplemented from Oscillator.

Definition at line 27 of file WavetableOscillator.cpp.

void WavetableOscillator::setSampleRate ( float  value)
virtual

Reimplemented from Oscillator.

Definition at line 23 of file WavetableOscillator.cpp.


The documentation for this class was generated from the following files: