Skip to content

TSM memory lost in JBM bitrate switching

In JBM, the time-scaled modified (TSM) buffer st_ivas->hTcBuffer->tc_buffer[] contains transport channels (TCs) samples subject to rendering. A short segment with a length less than the renderer granularity, which is part of this buffer, is the TSM memory, which is moved to the beginning of the TSM buffer at the next frame.

In case of bitrate switching, this buffer is reconfigured in the function ivas_jbm_dec_tc_buffer_reconfigure() where the whole buffer st_ivas->hTcBuffer->tc_buffer[] is freed and newly allocated again with the new configuration parameters. Consequently, the TSM part related to the TSM memory is lost (zeroed), which causes discontinuity in the TC audio signals and then also in the rendered audio signals.

The TSM buffer samples related to the TSM memory should thus be saved before the reallocation. It is important mainly in BINAURAL outputs when switching between bitrates with the TD decorrelator on and off.

A typical example of the discontinuity is reported at !2114 (comment 71937) for MASA bitrate switching (red=main, blue=fixed, frame 232):

image.png

However, the issue is also present in other IVAS formats or output configurations.

Edited by vaclav