ref: 0bb897211deb61bf76354330d8d9d9bf63ce7759
parent: b2baaa215bb0fe3072b1088e9b2ac65a88c50d30
author: Yaowu Xu <[email protected]>
date: Mon Apr 6 13:53:55 EDT 2015
Optimize the checking for transform skipping If U is not skippable, then do not perform the check on V. Change-Id: Iba5e8362bd42390197f373c44388a426a4404549
--- a/vp9/encoder/vp9_pickmode.c
+++ b/vp9/encoder/vp9_pickmode.c
@@ -391,10 +391,11 @@
var_uv[j] = cpi->fn_ptr[uv_bsize].vf(p->src.buf, p->src.stride,
pd->dst.buf, pd->dst.stride, &sse_uv[j]);
- if (var_uv[j] < uv_ac_thr || var_uv[j] == 0) {
- if (sse_uv[j] - var_uv[j] < uv_dc_thr || sse_uv[j] == var_uv[j])
- skip_uv[j] = 1;
- }
+ if ((var_uv[j] < uv_ac_thr || var_uv[j] == 0) &&
+ (sse_uv[j] - var_uv[j] < uv_dc_thr || sse_uv[j] == var_uv[j]))
+ skip_uv[j] = 1;
+ else
+ break;
}
// If the transform in YUV planes are skippable, the mode search checks