GainQuant_AMRWBE

Quantizes the adaptive codebook gains.

Syntax

IppStatus ippsGainQuant_AMRWBE_16s(Ipp16s* pSrcAdptTarget, const Ipp16s * pSrcFltAdptVector, int valFormat, const Ipp16s* pSrcFixedVector, const Ipp16s* pSrcFltFixedVector, int lenSrc, const Ipp16s* pSrcCorr, Ipp16s meanEnergy, Ipp16s* pSrcDstPitchGain, Ipp16s* pDstCorrFactor, Ipp32s* pDstCodeGain, Ipp16s* pDstQGainIndex);

Parameters

pSrcAdptTarget

Pointer to the input target vector x(n).

pSrcFltAdptVector

Pointer to the input filtered adaptive codebook vector y(n).

valFormat

Format of the pSrcAdptTarget and pSrcFltAdptVector vectors.

pSrcFixedVector

Pointer to the input pre-filtered codebook contribution c(n).

pSrcFltFixedVector

Pointer to the input filtered codebook vector z(n).

lenSrc

Length of the input vectors (n).

pSrcCorr

Pointer to the vector of correlations between the pSrcAdptTarget, pSrcFltAdptVector, pSrcFltFixedVector vectors.

meanEnergy

Average energy in the whole frame.

pSrcDstPitchGain

Pointer to the input/output pitch gain.

pDstCorrFactor

Pointer to the correction factor.

pDstCodeGain

Pointer to the output code gain.

pDstQGainIndex

Pointer to the output codebook indexes found.

Description

The function ippsGainQuant_AMRWBE is declared in ippsc.h file. This function quantizes the adaptive codebook gain (pitch gain) and the fixed (algebraic) codebook gain using the same 7-bit codebook that is used in the function ippsGainQuant_AMRWB for modes from 12.6 to 23.8 kbit/s. However, instead of using "moving average" prediction to obtain the predicted gain gC, it is found directly by quantizing the average energy meanEnergy in the whole frame.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

Indicates an error when one of the specified pointer is NULL.

ippStsSizeErr

Indicates an error when lenSrc is less than or equal to zero.

Submit feedback on this help topic

Copyright © 2000 - 2011, Intel Corporation. All rights reserved.