shithub: libvpx

Download patch

ref: 502ac7223328614cfd3af88764bcb866dbdba9da
parent: 1c39c5b96f7f2e212a09228bbd7062d33643b7bc
parent: 531468a07a62de99521e92377b440d7c87705812
author: Jingning Han <jingning@google.com>
date: Tue Mar 31 10:24:26 EDT 2015

Merge "Tuning SATD rate calculation for speed"

--- a/vp9/encoder/vp9_pickmode.c
+++ b/vp9/encoder/vp9_pickmode.c
@@ -401,7 +401,11 @@
         }
 
         *dist += vp9_block_error(coeff, dqcoeff, step << 4, &this_sse) >> shift;
-        *rate += (int)vp9_satd((const int16_t *)qcoeff, step << 4);
+
+        if (*eob == 1)
+          *rate += (int)abs(qcoeff[0]);
+        else if (*eob > 1)
+          *rate += (int)vp9_satd((const int16_t *)qcoeff, step << 4);
 
         *sse += (this_sse >> shift);
         *skippable &= (*eob == 0);