AudioScience HPI Version_4.10.
Functions

Compressor Expander control

Controls

The compander multiplies its input signal by a factor that is dependent on the amplitude of that signal. More...

Functions

hpi_err_t HPI_Compander_SetEnable (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint32_t enable)
 Enable or disable the compander.
hpi_err_t HPI_Compander_GetEnable (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint32_t *enable)
 Get the enable state of the compander.
hpi_err_t HPI_Compander_SetMakeupGain (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, short nMakeupGain0_01dB)
 Set the makeup gain of a compander control.
hpi_err_t HPI_Compander_GetMakeupGain (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, short *nMakeupGain0_01dB)
 Get the makeup gain of a compander control.
hpi_err_t HPI_Compander_SetAttackTimeConstant (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, uint32_t wAttack)
 Set the attack timeconstants.
hpi_err_t HPI_Compander_GetAttackTimeConstant (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, uint32_t *attack)
 Get the compander attack timeconstant.
hpi_err_t HPI_Compander_SetDecayTimeConstant (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, uint32_t decay)
 Set the decay timeconstants.
hpi_err_t HPI_Compander_GetDecayTimeConstant (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, uint32_t *decay)
 Get the compander attack timeconstant.
hpi_err_t HPI_Compander_SetThreshold (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, short nThreshold0_01dB)
 Set the threshold for one of the compander knee points.
hpi_err_t HPI_Compander_GetThreshold (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, unsigned int index, short *nThreshold0_01dB)
 Get the threshold for one of the compander knee points.
hpi_err_t HPI_Compander_SetRatio (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint32_t index, uint32_t wRatio100)
 Set the ratio for one of the compander knee points.
hpi_err_t HPI_Compander_GetRatio (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint32_t index, uint32_t *wRatio100)
 Set the ratio for one of the compander knee points.

Detailed Description

The compander multiplies its input signal by a factor that is dependent on the amplitude of that signal.


Function Documentation

hpi_err_t HPI_Compander_SetEnable ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
uint32_t  enable 
)

Enable or disable the compander.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
enable1=enable, 0=disable
hpi_err_t HPI_Compander_GetEnable ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
uint32_t *  enable 
)

Get the enable state of the compander.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
enable1=enabled, 0=disabled
hpi_err_t HPI_Compander_SetMakeupGain ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
short  nMakeupGain0_01dB 
)

Set the makeup gain of a compander control.

The makeup gain is applied independent of signal level, usually to compensate for level loss from compression.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
nMakeupGain0_01dBmakeup gain in 100ths of a dB
hpi_err_t HPI_Compander_GetMakeupGain ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
short *  nMakeupGain0_01dB 
)

Get the makeup gain of a compander control.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
nMakeupGain0_01dBmakeup gain in 100ths of a dB
hpi_err_t HPI_Compander_SetAttackTimeConstant ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
uint32_t  wAttack 
)

Set the attack timeconstants.

The attack timeconstant applies to the RMS detector on the compander or noise gate input.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
wAttackattack time in milliseconds
hpi_err_t HPI_Compander_GetAttackTimeConstant ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
uint32_t *  attack 
)

Get the compander attack timeconstant.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
attackattack time in milliseconds
hpi_err_t HPI_Compander_SetDecayTimeConstant ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
uint32_t  decay 
)

Set the decay timeconstants.

The decay timeconstant applies to the RMS detector on the compander or noise gate input.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
decaydecay time in milliseconds
hpi_err_t HPI_Compander_GetDecayTimeConstant ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
uint32_t *  decay 
)

Get the compander attack timeconstant.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
decaydecay time in milliseconds
hpi_err_t HPI_Compander_SetThreshold ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
short  nThreshold0_01dB 
)

Set the threshold for one of the compander knee points.

When index==0, the ratio is applied below the set threshold, otherwise the ratio is applied above the set threshold and below threshold with higher index (if any).

The threshold for index 0 must be less than that for index 1 etc.

/retval HPI_ERROR_INVALID_CONTROL_VALUE threshold outside valid range -100 to 0dB /retval HPI_ERROR_INVALID_OPERATION trying to set threshold 0 > threshold 1

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
nThreshold0_01dBthreshold in 100ths of a dB
hpi_err_t HPI_Compander_GetThreshold ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
unsigned int  index,
short *  nThreshold0_01dB 
)

Get the threshold for one of the compander knee points.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of
nThreshold0_01dBthreshold in 100ths of a dB
hpi_err_t HPI_Compander_SetRatio ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
uint32_t  index,
uint32_t  wRatio100 
)

Set the ratio for one of the compander knee points.

The actual ratio R is wRatio100/100.0 if index==0, for every R dB below the threshold, the output decreases by 1dB, else for every R dB above the threshold, the output increases by 1dB

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of knee point
wRatio100gain ratio * 100
hpi_err_t HPI_Compander_GetRatio ( const hpi_hsubsys_t *  phSubSys,
hpi_handle_t  hControl,
uint32_t  index,
uint32_t *  wRatio100 
)

Set the ratio for one of the compander knee points.

Parameters:
phSubSysVestigial subsys handle (unused), may be set to NULL
hControlCompander control handle
indexindex of
wRatio100gain ratio * 100