stereo DTX bitrate switching crash
There is an encoder crash for the following stereo DTX bitrate switching condition:
ivas_cod.exe -dtx -stereo scripts/switchPaths/sw_13k2_to_128k_10fr.bin 48 scripts/testv/stvST48n.wav bit
The crash happens in frame 980 which is the first TD stereo frame after a DFT frame. The crash happens in the secondary channel ACELP encoding:
if ( st->last_core_brate == FRAME_NO_DATA || st->last_core_brate == SID_2k40 )
{
mvr2r( st->hDtxEnc->lspCNG, st->lsp_old, M );
lsp2lsf( st->hDtxEnc->lspCNG, st->lsf_old, M, int_fs );
}
because st->hDtxEnc
is NULL in the TD stereo SCh. I think that the problem is however in the value of st->last_core_brate
which is set to 0 many frames before in the MDCT CNG frame and not updated correspondingly in the first TD stereo frame.
This issue was hidden due to a deactivation of the related self-test condition since November 2022 which happened in afaa34db.
Edited by vaclav