From: Deb Mukherjee Date: Fri, 29 Mar 2013 22:57:27 +0000 (-0700) Subject: Merge "Framework changes in nzc to allow more flexibility" into experimental X-Git-Tag: v1.3.0~1106^2~334 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e3955007dff1a32bb3b63f3f415b09c616f665a4;p=libvpx Merge "Framework changes in nzc to allow more flexibility" into experimental --- e3955007dff1a32bb3b63f3f415b09c616f665a4 diff --cc vp9/encoder/vp9_rdopt.c index 0083e8ae1,1f5b5dbb8..71dd6b80b --- a/vp9/encoder/vp9_rdopt.c +++ b/vp9/encoder/vp9_rdopt.c @@@ -595,16 -592,17 +592,17 @@@ static INLINE int cost_coeffs(VP9_COMMO [get_coef_band(scan, tx_size, c)] [pt][0], 1); #endif - pt = vp9_get_coef_context(scan, nb, pad, token_cache, c, default_eob); + pt = vp9_get_coef_context(scan, nb, pad, token_cache, c + 1, default_eob); } #if CONFIG_CODE_NONZEROCOUNT - cost += nzc_cost[nzc]; - #else - if (c < seg_eob) - cost += mb->token_costs[tx_size][type][ref] - [get_coef_band(scan, tx_size, c)] - [pt][DCT_EOB_TOKEN]; + if (nzc_used) + cost += nzc_cost[nzc]; + else #endif + if (c < seg_eob) + cost += mb->token_costs[tx_size][type][ref] + [get_coef_band(scan, tx_size, c)] + [pt][DCT_EOB_TOKEN]; } // is eob first coefficient;