diff options
author | Scott LaVarnway <slavarnway@google.com> | 2016-01-14 13:36:40 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2016-01-14 13:36:40 +0000 |
commit | d4bc17d6966ea779e6d0423d671969cd0417994d (patch) | |
tree | 5fd23d18124835c09d5828245eb3c680e2889f3d /vp9/common/vp9_entropymv.h | |
parent | 13177d7ecb036c074cc180414a40d4a042794d46 (diff) | |
parent | de993a847f8080d3128420c8ef8495642013bdb1 (diff) | |
download | libvpx-d4bc17d6966ea779e6d0423d671969cd0417994d.tar libvpx-d4bc17d6966ea779e6d0423d671969cd0417994d.tar.gz libvpx-d4bc17d6966ea779e6d0423d671969cd0417994d.tar.bz2 libvpx-d4bc17d6966ea779e6d0423d671969cd0417994d.zip |
Merge "VP9: inline vp9_use_mv_hp()"
Diffstat (limited to 'vp9/common/vp9_entropymv.h')
-rw-r--r-- | vp9/common/vp9_entropymv.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/vp9/common/vp9_entropymv.h b/vp9/common/vp9_entropymv.h index 8c817bf7b..2f05ad44b 100644 --- a/vp9/common/vp9_entropymv.h +++ b/vp9/common/vp9_entropymv.h @@ -27,7 +27,14 @@ struct VP9Common; void vp9_init_mv_probs(struct VP9Common *cm); void vp9_adapt_mv_probs(struct VP9Common *cm, int usehp); -int vp9_use_mv_hp(const MV *ref); + +// Integer pel reference mv threshold for use of high-precision 1/8 mv +#define COMPANDED_MVREF_THRESH 8 + +static INLINE int use_mv_hp(const MV *ref) { + return (abs(ref->row) >> 3) < COMPANDED_MVREF_THRESH && + (abs(ref->col) >> 3) < COMPANDED_MVREF_THRESH; +} #define MV_UPDATE_PROB 252 |