Audio Effects Framework
|
audio effect class for delay related effects More...
#include <AudioEffectDelay.h>
Public Types | |
enum | DelayType_t { kBasicDelay = 16, kChorus = 18, kFlanger = 21, kTremolo = 8, kVibrato = 2 } |
Public Types inherited from CAudioEffect | |
enum | EffectParam_t { kParamGain, kParamPan, kParamDelayInSecs, kParamFeedback, kParamModRateInHz, kParamModWidthInSecs, kParamTremoloAmount, kParamCenterFrequency, kParamQ, kParamThreshold, kParamSlope, kParamDryWetMix, kParamNumFilters, kParamFilterGains, kParamFilterDelays } |
Public Member Functions | |
CAudioEffectDelay () | |
CAudioEffectDelay (float fSampleRateInHz, int iNumChannels, DelayType_t subType=kBasicDelay, float iMaxDelayInSec=1.f, EffectParam_t params[]=NULL, float values[]=NULL, int iNumParams=0) | |
~CAudioEffectDelay () | |
Error_t | init (float fSampleRateInHz, int iNumChannels, DelayType_t subType=kBasicDelay, float iMaxDelayInSec=1.f, EffectParam_t params[]=NULL, float values[]=NULL, int iNumParams=0) |
Error_t | reset () |
Error_t | setParam (EffectParam_t eParam, float fValue) |
float | getParam (EffectParam_t eParam) |
Error_t | setDelayType (DelayType_t eValue) |
DelayType_t | getDelayType () |
Error_t | process (float **ppfInputBuffer, float **ppfOutputBuffer, int iNumberOfFrames) |
Public Member Functions inherited from CAudioEffect | |
CAudioEffect () | |
~CAudioEffect () | |
Effect_t | getEffectType () |
Additional Inherited Members | |
Protected Attributes inherited from CAudioEffect | |
bool | m_bIsInitialized |
true if initialized More... | |
Effect_t | m_eEffectType |
audio effect type More... | |
float | m_fSampleRateInHz |
sample rate in Hz More... | |
int | m_iNumChannels |
number of channels More... | |
audio effect class for delay related effects
CAudioEffectDelay::CAudioEffectDelay | ( | ) |
CAudioEffectDelay::CAudioEffectDelay | ( | float | fSampleRateInHz, |
int | iNumChannels, | ||
DelayType_t | subType = kBasicDelay , |
||
float | iMaxDelayInSec = 1.f , |
||
EffectParam_t | params[] = NULL , |
||
float | values[] = NULL , |
||
int | iNumParams = 0 |
||
) |
CAudioEffectDelay::~CAudioEffectDelay | ( | ) |
CAudioEffectDelay::DelayType_t CAudioEffectDelay::getDelayType | ( | ) |
return the value of the specified sub type
float CAudioEffectDelay::getParam | ( | EffectParam_t | eParam | ) |
return the value of the specified parameter
eParam |
Error_t CAudioEffectDelay::init | ( | float | fSampleRateInHz, |
int | iNumChannels, | ||
DelayType_t | subType = kBasicDelay , |
||
float | iMaxDelayInSec = 1.f , |
||
EffectParam_t | params[] = NULL , |
||
float | values[] = NULL , |
||
int | iNumParams = 0 |
||
) |
initializes a delay related effect instance
fSampleRateInHz | sample rate in Hz |
iNumChannels | number of audio channels |
iMaxDelayInSec | max delay length in seconds |
params[] | list of parameter types |
values[] | list of parameter values |
iNumParams | number of parameters |
Error_t CAudioEffectDelay::process | ( | float ** | ppfInputBuffer, |
float ** | ppfOutputBuffer, | ||
int | iNumberOfFrames | ||
) |
processes one block of audio
ppfInputBuffer | input buffer [numChannels][iNumberOfFrames] |
ppfOutputBuffer | output buffer [numChannels][iNumberOfFrames] |
iNumberOfFrames | buffer length (per channel) |
Error_t CAudioEffectDelay::reset | ( | ) |
resets the internal variables (requires new call of init)
Error_t CAudioEffectDelay::setDelayType | ( | DelayType_t | eValue | ) |
sets a delay related effect sub type
eValue | value of the sub type |
Error_t CAudioEffectDelay::setParam | ( | EffectParam_t | eParam, |
float | fValue | ||
) |
sets a delay related effect parameter
eParam | what parameter |
fValue | value of the parameter |