ASPiK SDK
Loading...
Searching...
No Matches
DynamicsProcessor Class Reference

The DynamicsProcessor object implements a dynamics processor suite: compressor, limiter, downward expander, gate. More...

#include <fxobjects.h>

Inheritance diagram for DynamicsProcessor:
IAudioSignalProcessor

Public Member Functions

virtual bool reset (double _sampleRate)
 
virtual bool canProcessAudioFrame ()
 
virtual void enableAuxInput (bool enableAuxInput)
 
virtual double processAuxInputAudioSample (double xn)
 
DynamicsProcessorParameters getParameters ()
 
void setParameters (const DynamicsProcessorParameters &_parameters)
 
virtual double processAudioSample (double xn)
 
- Public Member Functions inherited from IAudioSignalProcessor
virtual bool reset (double _sampleRate)=0
 
virtual double processAudioSample (double xn)=0
 
virtual bool canProcessAudioFrame ()=0
 
virtual void setSampleRate (double _sampleRate)
 
virtual void enableAuxInput (bool enableAuxInput)
 
virtual double processAuxInputAudioSample (double xn)
 
virtual bool processAudioFrame (const float *inputFrame, float *outputFrame, uint32_t inputChannels, uint32_t outputChannels)
 

Protected Member Functions

double computeGain (double detect_dB)
 

Protected Attributes

DynamicsProcessorParameters parameters
 object parameters
 
AudioDetector detector
 the sidechain audio detector
 
double sidechainInputSample = 0.0
 storage for sidechain sample
 

Detailed Description

The DynamicsProcessor object implements a dynamics processor suite: compressor, limiter, downward expander, gate.

Audio I/O:

  • Processes mono input to mono output.

Control I/F:

Author
Will Pirkle http://www.willpirkle.com
Remarks
This object is included in Designing Audio Effects Plugins in C++ 2nd Ed. by Will Pirkle
Version
Revision : 1.0
Date
Date : 2018 / 09 / 7

Member Function Documentation

◆ canProcessAudioFrame()

virtual bool DynamicsProcessor::canProcessAudioFrame ( )
inlinevirtual

return false: this object only processes samples

Implements IAudioSignalProcessor.

◆ computeGain()

double DynamicsProcessor::computeGain ( double  detect_dB)
inlineprotected

compute (and save) the current gain value based on detected input (dB)

◆ enableAuxInput()

virtual void DynamicsProcessor::enableAuxInput ( bool  enableAuxInput)
inlinevirtual

enable sidechaib input

Reimplemented from IAudioSignalProcessor.

◆ getParameters()

DynamicsProcessorParameters DynamicsProcessor::getParameters ( )
inline

get parameters: note use of custom structure for passing param data

Returns
DynamicsProcessorParameters custom data structure

◆ processAudioSample()

virtual double DynamicsProcessor::processAudioSample ( double  xn)
inlinevirtual

process audio using feed-forward dynamics processor flowchart

Parameters
xninput
Returns
the processed sample

Implements IAudioSignalProcessor.

◆ processAuxInputAudioSample()

virtual double DynamicsProcessor::processAuxInputAudioSample ( double  xn)
inlinevirtual

process the sidechain by saving the value for the upcoming processAudioSample() call

Reimplemented from IAudioSignalProcessor.

◆ reset()

virtual bool DynamicsProcessor::reset ( double  _sampleRate)
inlinevirtual

reset members to initialized state

Implements IAudioSignalProcessor.

◆ setParameters()

void DynamicsProcessor::setParameters ( const DynamicsProcessorParameters _parameters)
inline

set parameters: note use of custom structure for passing param data

Parameters
DynamicsProcessorParameterscustom data structure

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