webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Classes | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
WebCore::DynamicsCompressor Class Reference

#include <DynamicsCompressor.h>

Classes

struct  ZeroPoleFilterPack4
 

Public Types

enum  {
  ParamThreshold, ParamKnee, ParamRatio, ParamAttack,
  ParamRelease, ParamPreDelay, ParamReleaseZone1, ParamReleaseZone2,
  ParamReleaseZone3, ParamReleaseZone4, ParamPostGain, ParamFilterStageGain,
  ParamFilterStageRatio, ParamFilterAnchor, ParamEffectBlend, ParamReduction,
  ParamLast
}
 

Public Member Functions

 DynamicsCompressor (float sampleRate, unsigned numberOfChannels)
 
void process (const AudioBus *sourceBus, AudioBus *destinationBus, unsigned framesToProcess)
 
void reset ()
 
void setNumberOfChannels (unsigned)
 
void setParameterValue (unsigned parameterID, float value)
 
float parameterValue (unsigned parameterID)
 
float sampleRate () const
 
float nyquist () const
 
double tailTime () const
 
double latencyTime () const
 

Protected Member Functions

void initializeParameters ()
 
void setEmphasisStageParameters (unsigned stageIndex, float gain, float normalizedFrequency)
 
void setEmphasisParameters (float gain, float anchorFreq, float filterStageRatio)
 

Protected Attributes

unsigned m_numberOfChannels
 
float m_parameters [ParamLast]
 
float m_sampleRate
 
float m_lastFilterStageRatio
 
float m_lastAnchor
 
float m_lastFilterStageGain
 
Vector< std::unique_ptr< ZeroPoleFilterPack4 > > m_preFilterPacks
 
Vector< std::unique_ptr< ZeroPoleFilterPack4 > > m_postFilterPacks
 
std::unique_ptr< const float *[]> m_sourceChannels
 
std::unique_ptr< float *[]> m_destinationChannels
 
DynamicsCompressorKernel m_compressor
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
ParamThreshold 
ParamKnee 
ParamRatio 
ParamAttack 
ParamRelease 
ParamPreDelay 
ParamReleaseZone1 
ParamReleaseZone2 
ParamReleaseZone3 
ParamReleaseZone4 
ParamPostGain 
ParamFilterStageGain 
ParamFilterStageRatio 
ParamFilterAnchor 
ParamEffectBlend 
ParamReduction 
ParamLast 

Constructor & Destructor Documentation

◆ DynamicsCompressor()

WebCore::DynamicsCompressor::DynamicsCompressor ( float  sampleRate,
unsigned  numberOfChannels 
)

Member Function Documentation

◆ initializeParameters()

void WebCore::DynamicsCompressor::initializeParameters ( )
protected

◆ latencyTime()

double WebCore::DynamicsCompressor::latencyTime ( ) const
inline

◆ nyquist()

float WebCore::DynamicsCompressor::nyquist ( ) const
inline

◆ parameterValue()

float WebCore::DynamicsCompressor::parameterValue ( unsigned  parameterID)

◆ process()

void WebCore::DynamicsCompressor::process ( const AudioBus sourceBus,
AudioBus destinationBus,
unsigned  framesToProcess 
)

◆ reset()

void WebCore::DynamicsCompressor::reset ( )

◆ sampleRate()

float WebCore::DynamicsCompressor::sampleRate ( ) const
inline

◆ setEmphasisParameters()

void WebCore::DynamicsCompressor::setEmphasisParameters ( float  gain,
float  anchorFreq,
float  filterStageRatio 
)
protected

◆ setEmphasisStageParameters()

void WebCore::DynamicsCompressor::setEmphasisStageParameters ( unsigned  stageIndex,
float  gain,
float  normalizedFrequency 
)
protected

◆ setNumberOfChannels()

void WebCore::DynamicsCompressor::setNumberOfChannels ( unsigned  )

◆ setParameterValue()

void WebCore::DynamicsCompressor::setParameterValue ( unsigned  parameterID,
float  value 
)

◆ tailTime()

double WebCore::DynamicsCompressor::tailTime ( ) const
inline

Member Data Documentation

◆ m_compressor

DynamicsCompressorKernel WebCore::DynamicsCompressor::m_compressor
protected

◆ m_destinationChannels

std::unique_ptr<float*[]> WebCore::DynamicsCompressor::m_destinationChannels
protected

◆ m_lastAnchor

float WebCore::DynamicsCompressor::m_lastAnchor
protected

◆ m_lastFilterStageGain

float WebCore::DynamicsCompressor::m_lastFilterStageGain
protected

◆ m_lastFilterStageRatio

float WebCore::DynamicsCompressor::m_lastFilterStageRatio
protected

◆ m_numberOfChannels

unsigned WebCore::DynamicsCompressor::m_numberOfChannels
protected

◆ m_parameters

float WebCore::DynamicsCompressor::m_parameters[ParamLast]
protected

◆ m_postFilterPacks

Vector<std::unique_ptr<ZeroPoleFilterPack4> > WebCore::DynamicsCompressor::m_postFilterPacks
protected

◆ m_preFilterPacks

Vector<std::unique_ptr<ZeroPoleFilterPack4> > WebCore::DynamicsCompressor::m_preFilterPacks
protected

◆ m_sampleRate

float WebCore::DynamicsCompressor::m_sampleRate
protected

◆ m_sourceChannels

std::unique_ptr<const float*[]> WebCore::DynamicsCompressor::m_sourceChannels
protected

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