[FFmpeg-cvslog] avcodec/mpegaudiodec_template: use double to build csa tables

Michael Niedermayer git at videolan.org
Fri Apr 17 14:34:45 CEST 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Apr 17 13:36:14 2015 +0200| [8768f8f4b92990e5b9c5df1024438122532998d4] | committer: Michael Niedermayer

avcodec/mpegaudiodec_template: use double to build csa tables

Fixes rounding difference between 32bit x86 and 64bit
Fixes fate failure with gapless mp3

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=8768f8f4b92990e5b9c5df1024438122532998d4
---

 libavcodec/mpegaudiodec_template.c |    2 +-
 tests/ref/fate/gapless-mp3         |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/libavcodec/mpegaudiodec_template.c b/libavcodec/mpegaudiodec_template.c
index 138a107..2326a90 100644
--- a/libavcodec/mpegaudiodec_template.c
+++ b/libavcodec/mpegaudiodec_template.c
@@ -388,7 +388,7 @@ static av_cold void decode_init_static(void)
     }
 
     for (i = 0; i < 8; i++) {
-        float ci, cs, ca;
+        double ci, cs, ca;
         ci = ci_table[i];
         cs = 1.0 / sqrt(1.0 + ci * ci);
         ca = cs * ci;
diff --git a/tests/ref/fate/gapless-mp3 b/tests/ref/fate/gapless-mp3
index 9add70f..2c178c0 100644
--- a/tests/ref/fate/gapless-mp3
+++ b/tests/ref/fate/gapless-mp3
@@ -1,4 +1,4 @@
 d5c88cf38416329a052a9b0cb140fb4c *tests/data/fate/gapless-mp3.out-1
-3e41cbd4dcd511d3155234684252beab
+c96c3ae7bd3300fd2f4debac222de5b7
 68f040b12d79c71e3b2e8ba90a9cbd96 *tests/data/fate/gapless-mp3.out-2
-3e41cbd4dcd511d3155234684252beab
\ No newline at end of file
+c96c3ae7bd3300fd2f4debac222de5b7



More information about the ffmpeg-cvslog mailing list