aboutsummaryrefslogtreecommitdiffstats
path: root/libSBRdec/src
diff options
context:
space:
mode:
authorJean-Michel Trivi <jmtrivi@google.com>2013-04-18 10:59:16 -0700
committerJean-Michel Trivi <jmtrivi@google.com>2013-08-05 19:23:49 +0000
commit8bd0baee9e37c226c6e30593be90e8ecdb559f2e (patch)
tree9e8923c71a5358b806d7131302f902475deb4fc2 /libSBRdec/src
parentdd68dcdb756966b80ad86268d7fe45b3434374c9 (diff)
downloadfdk-aac-dabplus-8bd0baee9e37c226c6e30593be90e8ecdb559f2e.tar.gz
fdk-aac-dabplus-8bd0baee9e37c226c6e30593be90e8ecdb559f2e.tar.bz2
fdk-aac-dabplus-8bd0baee9e37c226c6e30593be90e8ecdb559f2e.zip
Fix HE-AAC SBR ignored high-freq data
Change-Id: I12d284477f07349368e714ba52cbb2a47b024554 (cherry picked from commit a889574e60a02bbc647d3b078d2727cb48d82e5a)
Diffstat (limited to 'libSBRdec/src')
-rw-r--r--libSBRdec/src/sbr_rom.cpp2
-rw-r--r--libSBRdec/src/sbr_rom.h2
-rw-r--r--libSBRdec/src/sbrdec_freq_sca.cpp7
-rw-r--r--libSBRdec/src/sbrdecoder.cpp4
4 files changed, 13 insertions, 2 deletions
diff --git a/libSBRdec/src/sbr_rom.cpp b/libSBRdec/src/sbr_rom.cpp
index 8520b14..8975dd4 100644
--- a/libSBRdec/src/sbr_rom.cpp
+++ b/libSBRdec/src/sbr_rom.cpp
@@ -110,6 +110,8 @@ const UCHAR FDK_sbrDecoder_sbr_start_freq_32[16] = {10, 12, 14, 15, 16, 17, 18,
const UCHAR FDK_sbrDecoder_sbr_start_freq_40[16] = {12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 24, 26, 28, 30, 32};
const UCHAR FDK_sbrDecoder_sbr_start_freq_44[16] = { 8, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 23, 25, 28, 32};
const UCHAR FDK_sbrDecoder_sbr_start_freq_48[16] = { 7, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 22, 24, 27, 31};
+const UCHAR FDK_sbrDecoder_sbr_start_freq_64[16] = { 6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 19, 21, 23, 26, 30};
+const UCHAR FDK_sbrDecoder_sbr_start_freq_88[16] = { 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 18, 20, 23, 27, 31};
//@}
diff --git a/libSBRdec/src/sbr_rom.h b/libSBRdec/src/sbr_rom.h
index 912f7e4..2fff95c 100644
--- a/libSBRdec/src/sbr_rom.h
+++ b/libSBRdec/src/sbr_rom.h
@@ -106,6 +106,8 @@ extern const UCHAR FDK_sbrDecoder_sbr_start_freq_32[16];
extern const UCHAR FDK_sbrDecoder_sbr_start_freq_40[16];
extern const UCHAR FDK_sbrDecoder_sbr_start_freq_44[16];
extern const UCHAR FDK_sbrDecoder_sbr_start_freq_48[16];
+extern const UCHAR FDK_sbrDecoder_sbr_start_freq_64[16];
+extern const UCHAR FDK_sbrDecoder_sbr_start_freq_88[16];
/*
Low-Power-Profile Transposer
diff --git a/libSBRdec/src/sbrdec_freq_sca.cpp b/libSBRdec/src/sbrdec_freq_sca.cpp
index b877545..e9023ee 100644
--- a/libSBRdec/src/sbrdec_freq_sca.cpp
+++ b/libSBRdec/src/sbrdec_freq_sca.cpp
@@ -124,6 +124,13 @@ getStartBand(UINT fs, /*!< Output sampling frequency */
fsMapped = fs;
switch (fsMapped) {
+ case 96000:
+ case 88200:
+ band = FDK_sbrDecoder_sbr_start_freq_88[startFreq];
+ break;
+ case 64000:
+ band = FDK_sbrDecoder_sbr_start_freq_64[startFreq];
+ break;
case 48000:
band = FDK_sbrDecoder_sbr_start_freq_48[startFreq];
break;
diff --git a/libSBRdec/src/sbrdecoder.cpp b/libSBRdec/src/sbrdecoder.cpp
index 192bdd2..3b3fcc5 100644
--- a/libSBRdec/src/sbrdecoder.cpp
+++ b/libSBRdec/src/sbrdecoder.cpp
@@ -217,14 +217,14 @@ SBR_ERROR sbrDecoder_ResetElement (
/* Check in/out samplerates */
if ( sampleRateIn < 6400
- || sampleRateIn > 24000
+ || sampleRateIn > 48000
)
{
sbrError = SBRDEC_UNSUPPORTED_CONFIG;
goto bail;
}
- if ( sampleRateOut > 48000 )
+ if ( sampleRateOut > 96000 )
{
sbrError = SBRDEC_UNSUPPORTED_CONFIG;
goto bail;