diff options
author | Yaowu Xu <yaowu@google.com> | 2011-12-08 11:43:09 -0800 |
---|---|---|
committer | Yaowu Xu <yaowu@google.com> | 2011-12-09 14:44:13 -0800 |
commit | be360d47f412424e1bf1d645860ccabdad2f3343 (patch) | |
tree | 5a4d41b8449ffe2770417ce9adc3a4de3da2cccb /vp8/encoder/modecosts.c | |
parent | 43a059de71e73e4eefd620d684f50c8a4c7a5e1d (diff) | |
download | libvpx-be360d47f412424e1bf1d645860ccabdad2f3343.tar libvpx-be360d47f412424e1bf1d645860ccabdad2f3343.tar.gz libvpx-be360d47f412424e1bf1d645860ccabdad2f3343.tar.bz2 libvpx-be360d47f412424e1bf1d645860ccabdad2f3343.zip |
Enabled adaptive UV intra coding for inter frames
Previously, Y-adaptive UV intra coding only enabled on key frames in
UVINTRA experiment. This commit enabled the same coding for inter
frames, so the encoding of UV intra modes are consistent cross all
frame types. Tests on derf set showed a very small overall gain around
.04%:
http://www.corp.google.com/~yaowu/no_crawl/interUVintra.html
The gain looks to be reasonable given inta coded MBs is only a
small portion of MBs in inter frames.
Change-Id: Ic6fc261923f2c253f4a0c9f8bccf4797557b9e16
Diffstat (limited to 'vp8/encoder/modecosts.c')
-rw-r--r-- | vp8/encoder/modecosts.c | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/vp8/encoder/modecosts.c b/vp8/encoder/modecosts.c index 36fea9f9f..b6f77e1a1 100644 --- a/vp8/encoder/modecosts.c +++ b/vp8/encoder/modecosts.c @@ -37,20 +37,28 @@ void vp8_init_mode_costs(VP8_COMP *c) vp8_cost_tokens((int *)c->mb.inter_bmode_costs, x->fc.bmode_prob, T); } - vp8_cost_tokens((int *)c->mb.inter_bmode_costs, x->fc.sub_mv_ref_prob, vp8_sub_mv_ref_tree); + vp8_cost_tokens((int *)c->mb.inter_bmode_costs, + x->fc.sub_mv_ref_prob, vp8_sub_mv_ref_tree); vp8_cost_tokens(c->mb.mbmode_cost[1], x->fc.ymode_prob, vp8_ymode_tree); #if CONFIG_QIMODE vp8_cost_tokens(c->mb.mbmode_cost[0], - x->kf_ymode_prob[c->common.kf_ymode_probs_index], vp8_kf_ymode_tree); + x->kf_ymode_prob[c->common.kf_ymode_probs_index], + vp8_kf_ymode_tree); #else - vp8_cost_tokens(c->mb.mbmode_cost[0], x->kf_ymode_prob, vp8_kf_ymode_tree); + vp8_cost_tokens(c->mb.mbmode_cost[0], + x->kf_ymode_prob, vp8_kf_ymode_tree); #endif - vp8_cost_tokens(c->mb.intra_uv_mode_cost[1], x->fc.uv_mode_prob, vp8_uv_mode_tree); #if CONFIG_UVINTRA - vp8_cost_tokens(c->mb.intra_uv_mode_cost[0], x->kf_uv_mode_prob[VP8_YMODES-1], vp8_uv_mode_tree); + vp8_cost_tokens(c->mb.intra_uv_mode_cost[1], + x->fc.uv_mode_prob[VP8_YMODES-1], vp8_uv_mode_tree); + vp8_cost_tokens(c->mb.intra_uv_mode_cost[0], + x->kf_uv_mode_prob[VP8_YMODES-1], vp8_uv_mode_tree); #else - vp8_cost_tokens(c->mb.intra_uv_mode_cost[0], x->kf_uv_mode_prob, vp8_uv_mode_tree); + vp8_cost_tokens(c->mb.intra_uv_mode_cost[1], + x->fc.uv_mode_prob, vp8_uv_mode_tree); + vp8_cost_tokens(c->mb.intra_uv_mode_cost[0], + x->kf_uv_mode_prob, vp8_uv_mode_tree); #endif vp8_cost_tokens(c->mb.i8x8_mode_costs, x->i8x8_mode_prob,vp8_i8x8_mode_tree); |