struct macroblock_plane *const p = &x->plane[i];
struct macroblockd_plane *const pd = &xd->plane[i];
const BLOCK_SIZE bs = get_plane_block_size(bsize, pd);
+
(void) cpi->fn_ptr[bs].vf(p->src.buf, p->src.stride,
pd->dst.buf, pd->dst.stride, &sse);
+
if (i == 0)
x->pred_sse[ref] = sse;
-
- dist_sum += (int)sse;
+ if (cpi->compressor_speed > 2) {
+ dist_sum += (int)sse;
+ } else {
+ int rate;
+ int64_t dist;
+ model_rd_from_var_lapndz(sse, 1 << num_pels_log2_lookup[bs],
+ pd->dequant[1] >> 3, &rate, &dist);
+ rate_sum += rate;
+ dist_sum += (int)dist;
+ }
}
*out_rate_sum = rate_sum;