diff snow.h @ 5565:93082c591c8b libavcodec

Change rounding of the horizontal DWT to match the vertical one. This allows some simplifications and optimizations and should not have any effect on quality.
author michael
date Tue, 21 Aug 2007 16:29:40 +0000
parents 8dcb8c89a661
children 3ae03eacbe9f
line wrap: on
line diff
--- a/snow.h	Tue Aug 21 15:48:08 2007 +0000
+++ b/snow.h	Tue Aug 21 16:29:40 2007 +0000
@@ -165,11 +165,11 @@
 
 static av_always_inline void snow_horizontal_compose_liftS_lead_out(int i, DWTELEM * dst, DWTELEM * src, DWTELEM * ref, int width, int w){
         for(; i<w; i++){
-            dst[i] = src[i] + ((ref[i] + ref[(i+1)]+W_BO-1 + 4 * src[i]) >> W_BS);
+            dst[i] = src[i] + ((ref[i] + ref[(i+1)]+W_BO + 4 * src[i]) >> W_BS);
         }
 
         if(width&1){
-            dst[w] = src[w] + ((2 * ref[w] + W_BO-1 + 4 * src[w]) >> W_BS);
+            dst[w] = src[w] + ((2 * ref[w] + W_BO + 4 * src[w]) >> W_BS);
         }
 }