[xiph-commits] r18268 - trunk/theora/lib

tterribe at svn.xiph.org tterribe at svn.xiph.org
Mon May 7 19:51:57 PDT 2012


Author: tterribe
Date: 2012-05-07 19:51:57 -0700 (Mon, 07 May 2012)
New Revision: 18268

Modified:
   trunk/theora/lib/decode.c
Log:
Fix pp_sharp_mod calculation.

This was broken when the dequant_tables indexing changed in commit
 r16102, but it only affected post-processing quality, so we never
 noticed.
With gcc 4.8.0, this can now trigger a segfault during decoder
 initialization.


Modified: trunk/theora/lib/decode.c
===================================================================
--- trunk/theora/lib/decode.c	2012-05-07 00:48:30 UTC (rev 18267)
+++ trunk/theora/lib/decode.c	2012-05-08 02:51:57 UTC (rev 18268)
@@ -400,10 +400,10 @@
     int qsum;
     qsum=0;
     for(qti=0;qti<2;qti++)for(pli=0;pli<3;pli++){
-      qsum+=_dec->state.dequant_tables[qti][pli][qi][12]+
-       _dec->state.dequant_tables[qti][pli][qi][17]+
-       _dec->state.dequant_tables[qti][pli][qi][18]+
-       _dec->state.dequant_tables[qti][pli][qi][24]<<(pli==0);
+      qsum+=_dec->state.dequant_tables[qi][pli][qti][12]+
+       _dec->state.dequant_tables[qi][pli][qti][17]+
+       _dec->state.dequant_tables[qi][pli][qti][18]+
+       _dec->state.dequant_tables[qi][pli][qti][24]<<(pli==0);
     }
     _dec->pp_sharp_mod[qi]=-(qsum>>11);
   }



More information about the commits mailing list