Finds pitch and fixed gains.
IppStatus ippsGainCodebookSearch_G729_32f( const Ipp32f* pSrcCorrFactors, Ipp32f valPredictedCodebookGain, const int* pSrcCand, Ipp32f* pDstIdxs, Ipp32s valTimeFlag);
IppStatus ippsGainCodebookSearch_G729D_32f (const Ipp32f* pSrcCorrFactors, Ipp32f valPredictedCodebookGain, const int* pSrcCand, Ipp32f* pDstIdxs, Ipp32s valTimeFlag);
pSrcCorrFactors |
Pointer to the correlations. |
valPredictedCodebookGain |
Predicted codebook gain. |
pSrcCand |
Pointer to the pre-searched candidates. |
pDstIdxs |
Pointer to the output indexes. |
valTimeFlag |
Taming process indicator. |
The functions ippsGainCodebookSearch_G729 and ippsGainCodebookSearch_G729D are declared in the ipps.h file. As part of LSP quantization algorithm (refer to ippsGainQuant_G729 for details), these functions operate in floating-point arithmetic and perform selection of the gain vector in the codebook GA and GB in the range limited by pSrcCand[0] and pSrcCand[1]. The search algorithm consists of minimizing the following expression:
E = pSrcCorrFactors[0] x Gp2 + pSrcCorrFactors[2] x Gc2 + pSrcCorrFactors[1] x Gp + pSrcCorrFactors[3] x Gc + pSrcCorrFactors[1] x Gp x Gc,
where Gp and Gc are optimum pitch and code gains, respectively, in selected domain.
The ippsGainCodebookSearch_G729_32f function uses the 7-bit codebook, whereas the function ippsGainCodebookSearch_G729D_32f uses the 6-bit codebook.
ippStsNoErr |
Indicates no error. |
ippStsNullPtrErr |
Indicates an error when one of the specified pointers is NULL. |
ippStsRangeErr |
Indicates an error when valTimeFlag is not 0 or 1. |
ippStsRangeErr |
For the G729 function flavor: indicates an error when pSrcCand[0] is not in the range [0,4) or pSrcCand[1] is not in the range [0,8). For the G729D function flavor: indicates an error when pSrcCand[0] or pSrcCand[1] is not in the range [0,2). |
Copyright © 2000 - 2011, Intel Corporation. All rights reserved.