diff options
author | Dmitry Kovalev <dkovalev@google.com> | 2013-11-05 11:58:57 -0800 |
---|---|---|
committer | Dmitry Kovalev <dkovalev@google.com> | 2013-11-05 11:58:57 -0800 |
commit | 815189613bcf61aebe808047f5a35f14d25c4f69 (patch) | |
tree | 74351737e2613a11535cbcb5e41814f5efcb2eab /vp9/decoder/vp9_decodemv.c | |
parent | 69cb7dc83921c7ddc5b146c9bd5c8e796020852b (diff) | |
download | libvpx-815189613bcf61aebe808047f5a35f14d25c4f69.tar libvpx-815189613bcf61aebe808047f5a35f14d25c4f69.tar.gz libvpx-815189613bcf61aebe808047f5a35f14d25c4f69.tar.bz2 libvpx-815189613bcf61aebe808047f5a35f14d25c4f69.zip |
Localizing NEARESTMV special cases in the code.
Removing special case handling from vp9_tree_probs_from_distribution(),
tree_merge_probs(), and vp9_tokens_from_tree_offset() functions. Replacing
inter_mode_offset() function with macro INTER_OFFSET which is used now for
vp9_inter_mode_tree definition.
Change-Id: Iff75a1499d460beb949ece543389c8754deaf178
Diffstat (limited to 'vp9/decoder/vp9_decodemv.c')
-rw-r--r-- | vp9/decoder/vp9_decodemv.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/vp9/decoder/vp9_decodemv.c b/vp9/decoder/vp9_decodemv.c index 1ca578621..e54bd7946 100644 --- a/vp9/decoder/vp9_decodemv.c +++ b/vp9/decoder/vp9_decodemv.c @@ -48,12 +48,13 @@ static MB_PREDICTION_MODE read_intra_mode_uv(VP9_COMMON *cm, vp9_reader *r, } static MB_PREDICTION_MODE read_inter_mode(VP9_COMMON *cm, vp9_reader *r, - uint8_t context) { - const MB_PREDICTION_MODE mode = treed_read(r, vp9_inter_mode_tree, - cm->fc.inter_mode_probs[context]); + int ctx) { + const int mode = treed_read(r, vp9_inter_mode_tree, + cm->fc.inter_mode_probs[ctx]); if (!cm->frame_parallel_decoding_mode) - ++cm->counts.inter_mode[context][inter_mode_offset(mode)]; - return mode; + ++cm->counts.inter_mode[ctx][mode]; + + return NEARESTMV + mode; } static int read_segment_id(vp9_reader *r, const struct segmentation *seg) { |