EncDTXHandler_GSMAMR

Determines the SID flag of current frame.

Syntax

IppStatus ippsEncDTXHandler_GSMAMR_16s(Ipp16s* pValResultHangOverCount, Ipp16s* pValResultDtxElapsedCount, Ipp16s* pValResultUsedMode, Ipp16s* pResultSidFlag, Ipp16s vadFlag);

Parameters

pValResultHangOverCount

Pointer to the DTX hangover count. When initialized or reset, it is set to 0. On output, points to the updated DTX hangover count.

pValResultDtxElapsedCount

Pointer to the elapsed frame count since the last non-DTX frame. When initialized or reset, it is set to “0”. On output, points to the updated elapsed frame count since the last non-DTX frame.

pValResultUsedMode

Pointer to the transmission mode. At the input stage, the mode is one of the bit rate modes ranging from 4.75 Kbps to 12.2 Kbps. At the output stage, this value is either unchanged or set to the DTX frame mode.

pResultSidFlag

Pointer to the output SID flag, “1” indicates a SID frame, and “0” indicates a non-SID frame.

vadFlag

This is the VAD flag of the current frame, if it is set to “1”, the current frame is marked as voiced, and if it is set to “0”, it is marked as unvoiced.

Description

The function ippsEncDTXHandler_GSMAMR is declared in ippsc.h file. This function determines the SID flag of current frame, and it determines whether the current frame should use DTX encoding, as follows:


  1. Update the elapsed frame count since last SID frame: DTX_ElapsedCount = DTX_ElapsedCount + 1(Bounded to 0~0x7fff).
  2. If the VAD flag of current frame is 1 (voiced frame), the DTX hangover count is set to 7, and this function ends.
  3. If the VAD flag of current frame is 0 (unvoiced frame), and the DTX hangover count is 0, the transmission mode of this frame is set to DTX frame mode, and the elapsed frame count since last DTX frame is set to 0, the SID flag is set to 1.
  4. If the VAD flag of current frame is 0 (unvoiced frame), but the DTX hangover count is not 0, then decrease DTX hangover count by 1, and if DTX_HangOver_Count + DTX_ElapsedCount < 30 the SID flag is set to 0, and the transmission mode is set to MRDTX.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

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

Submit feedback on this help topic

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