GainQuant_AMRWB

Quantizes the adaptive codebook gains.

Syntax

IppStatus ippsGainQuant_AMRWB_16s(const Ipp16s* pSrcAdptTarget, const Ipp16s* pSrcFltAdptVector, int valFormat, const Ipp16s* pSrcFixedVector, const Ipp16s* pSrcFltFixedVector, const Ipp16s* pSrcCorr, Ipp16s* pSrcDstEnergyErr, Ipp16s* pSrcDstPitchGain, int* pDstCodeGain, int valClipFlag, Ipp16s* pDstQGainIndex, int lenSrc, IppSpchBitRate mode);

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).

pSrcCorr

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

pSrcDstEnergyErr

Pointer to the input/output energy error vector for the four most recent subframes.

pSrcDstPitchGain

Pointer to the input/output pitch gain.

pDstCodeGain

Pointer to the output code gain.

valClipFlag

If valClipFlag = 1 , then limit gain pitch to 1.0.

pDstQGainIndex

Pointer to the output codebook indexes found.

lenSrc

Length of the input vectors.

mode

Encoding mode.

Description

This function is declared in ippsc.h file. The adaptive codebook gain (pitch gain) and the fixed (algebraic) codebook gain are vector quantized using a 6-bit codebook for modes 8.85 and 6.60 kbit/s and using a 7-bit codebook for all the other modes.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

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

ippStsSizeErr

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

ippStsRangeErr

Indicates an error when mode is not a valid element of the enumerated type IppSpchBitRate.

Submit feedback on this help topic

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