diff options
author | Jean-Michel Trivi <jmtrivi@google.com> | 2018-12-28 15:18:34 -0800 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2018-12-28 15:18:34 -0800 |
commit | d93de565ac84079f5774a13e61cd31b46b242575 (patch) | |
tree | 784e95623f8f23bd22eab70c9168383a37589502 /libMpegTPDec/src/tpdec_asc.cpp | |
parent | 2f583c7ab768da9f3c5627a972b0c1c610ab45e2 (diff) | |
parent | 7e454bd098434338fa6da8d4a8164762d3abed0f (diff) | |
download | fdk-aac-d93de565ac84079f5774a13e61cd31b46b242575.tar.gz fdk-aac-d93de565ac84079f5774a13e61cd31b46b242575.tar.bz2 fdk-aac-d93de565ac84079f5774a13e61cd31b46b242575.zip |
Merge "Setup lowdelay SBR LFE element via SBR callback" am: 3e0a7a40c5
am: 7e454bd098
Change-Id: Ida1f2655913afe2f16b3efd9464b2c7027732d17
Diffstat (limited to 'libMpegTPDec/src/tpdec_asc.cpp')
-rw-r--r-- | libMpegTPDec/src/tpdec_asc.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libMpegTPDec/src/tpdec_asc.cpp b/libMpegTPDec/src/tpdec_asc.cpp index 6260cad..3b61eef 100644 --- a/libMpegTPDec/src/tpdec_asc.cpp +++ b/libMpegTPDec/src/tpdec_asc.cpp @@ -1300,7 +1300,11 @@ static INT ld_sbr_header(CSAudioSpecificConfig *asc, const INT dsFactor, /* read elements of the passed channel_configuration until there is ID_NONE */ while ((element = channel_configuration_array[channelConfiguration][j]) != ID_NONE) { - if (element == ID_SCE || element == ID_CPE) { + /* Setup LFE element for upsampling too. This is essential especially for + * channel configs where the LFE element is not at the last position for + * example in channel config 13 or 14. It leads to memory leaks if the setup + * of the LFE element would be done later in the core. */ + if (element == ID_SCE || element == ID_CPE || element == ID_LFE) { error |= cb->cbSbr( cb->cbSbrData, hBs, asc->m_samplingFrequency / dsFactor, asc->m_extensionSamplingFrequency / dsFactor, |