AudioScience HPI Version_4.24.1
|
The meter control returns information about the level of the audio signal at the position of the control. More...
Defines | |
#define | HPI_METER_MINIMUM (-150 * HPI_UNITS_PER_dB) |
value returned for no signal | |
Functions | |
hpi_err_t | HPI_Meter_QueryChannels (const hpi_hsubsys_t *phSubSys, const hpi_handle_t hMeter, uint32_t *pChannels) |
Get the number of channels supported by this meter. | |
hpi_err_t | HPI_MeterGetPeak (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, short anPeakdB[HPI_MAX_CHANNELS]) |
Get the meter peak reading. | |
hpi_err_t | HPI_MeterGetRms (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, short anRmsdB[HPI_MAX_CHANNELS]) |
Get the meter RMS reading in 100ths of a dB. | |
hpi_err_t | HPI_MeterSetRmsBallistics (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint16_t nAttack, uint16_t nDecay) |
Set the ballistics of the RMS part of a meter. | |
hpi_err_t | HPI_MeterGetRmsBallistics (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint16_t *pnAttack, uint16_t *pnDecay) |
Get the ballistics settings of the RMS part of a meter. | |
hpi_err_t | HPI_MeterSetPeakBallistics (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint16_t nAttack, uint16_t nDecay) |
Set the ballistics of the Peak part of a meter. | |
hpi_err_t | HPI_MeterGetPeakBallistics (const hpi_hsubsys_t *phSubSys, hpi_handle_t hControl, uint16_t *pnAttack, uint16_t *pnDecay) |
Get the ballistics settings of the Peak part of a meter. |
The meter control returns information about the level of the audio signal at the position of the control.
Depending on the adapter, Peak and RMS readings are available. On some adapters meter ballistics may be set (on older adapters the meter gives an instantaneous reading)
Readings are in units of 0.01dB
#define HPI_METER_MINIMUM (-150 * HPI_UNITS_PER_dB) |
value returned for no signal
Referenced by HPI_MeterGetPeak(), and HPI_MeterGetRms().
hpi_err_t HPI_Meter_QueryChannels | ( | const hpi_hsubsys_t * | phSubSys, |
const hpi_handle_t | hMeter, | ||
uint32_t * | pChannels | ||
) |
Get the number of channels supported by this meter.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hMeter | Control to query |
pChannels | number of channels |
References HPI_ControlQuery().
hpi_err_t HPI_MeterGetPeak | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
short | anPeakdB[HPI_MAX_CHANNELS] | ||
) |
Get the meter peak reading.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | meter control handle |
anPeakdB | meter peaks in millibels |
References HPI_METER_MINIMUM.
hpi_err_t HPI_MeterGetRms | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
short | anRmsdB[HPI_MAX_CHANNELS] | ||
) |
Get the meter RMS reading in 100ths of a dB.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | meter control handle |
anRmsdB | meter RMS values in millibels |
References HPI_METER_MINIMUM.
hpi_err_t HPI_MeterSetRmsBallistics | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
uint16_t | nAttack, | ||
uint16_t | nDecay | ||
) |
Set the ballistics of the RMS part of a meter.
The attack and decay values represent the time constants of the equivalent single pole low pass filter used to create the ballistics. With a time constant of T, if the meter is stable at full scale and the input is suddenly removed, the meter will decay.
Setting nAttack to 0 gives the meter instantaneous rise time. Setting nDecay to a value smaller than a few times your meter polling interval is not advised. The meter will appear to read something approaching the instantaneous value at the time of polling rather than the maximum peak since the previous reading.
Driver versions up to and including version 4.04.xx implement a single global ballistics setting for all meters, i.e. if you change the ballistics on one meter, the ballistics on all meters are updated. Driver versions in the 4.05.xx series and later implement independent ballistics for each meter.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | Handle to control of type HPI_CONTROL_METER |
nAttack | Attack timeconstant in milliseconds |
nDecay | Decay timeconstant in milliseconds |
hpi_err_t HPI_MeterGetRmsBallistics | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
uint16_t * | pnAttack, | ||
uint16_t * | pnDecay | ||
) |
Get the ballistics settings of the RMS part of a meter.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | Handle to control of type HPI_CONTROL_METER |
pnAttack | Attack timeconstant in milliseconds |
pnDecay | Decay timeconstant in milliseconds |
hpi_err_t HPI_MeterSetPeakBallistics | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
uint16_t | nAttack, | ||
uint16_t | nDecay | ||
) |
Set the ballistics of the Peak part of a meter.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | Handle to control of type HPI_CONTROL_METER |
nAttack | Attack timeconstant in milliseconds |
nDecay | Decay timeconstant in milliseconds |
hpi_err_t HPI_MeterGetPeakBallistics | ( | const hpi_hsubsys_t * | phSubSys, |
hpi_handle_t | hControl, | ||
uint16_t * | pnAttack, | ||
uint16_t * | pnDecay | ||
) |
Get the ballistics settings of the Peak part of a meter.
phSubSys | Vestigial subsys handle (unused), may be set to NULL |
hControl | Handle to control of type HPI_CONTROL_METER |
pnAttack | Attack timeconstant in milliseconds |
pnDecay | Decay timeconstant in milliseconds |