From 11abab356e4c04d4a21ac43f58f9ec05c7c80eca Mon Sep 17 00:00:00 2001 From: Jingning Han Date: Fri, 27 Sep 2013 16:02:49 -0700 Subject: Refactor inter mode rate-distortion search This commit separates the rate-distortion optimization loop of superblocks from that of sub8x8 blocks. This allows better design rate-distortion optimization search loop for each setting. It also removes the use of SPLITMV and I4X4_PRED therein. No performance change in speed 0 settings. For bus@CIF at 2000kbps, the speed 1 runtime goes from 48009ms to 43894ms (about 10% faster). The overall compression performance on derf changed by -0.021%. Speed 2 runtime goes from 27114ms to 28700ms (6% slower), while the overall coding efficiency goes up by 1.629% for derf, 1.236% for yt. Change-Id: Ie6bdfa0a370148dd60bd800961077f7e97e67dd4 --- vp9/encoder/vp9_encodemb.h | 27 ++++++--------------------- 1 file changed, 6 insertions(+), 21 deletions(-) (limited to 'vp9/encoder/vp9_encodemb.h') diff --git a/vp9/encoder/vp9_encodemb.h b/vp9/encoder/vp9_encodemb.h index 54e69fd9d..61dd7358e 100644 --- a/vp9/encoder/vp9_encodemb.h +++ b/vp9/encoder/vp9_encodemb.h @@ -16,32 +16,17 @@ #include "vp9/encoder/vp9_onyx_int.h" #include "vp9/common/vp9_onyxc_int.h" -typedef enum { - RD_DC_PRED = DC_PRED, - RD_V_PRED = V_PRED, - RD_H_PRED = H_PRED, - RD_D45_PRED = D45_PRED, - RD_D135_PRED = D135_PRED, - RD_D117_PRED = D117_PRED, - RD_D153_PRED = D153_PRED, - RD_D207_PRED = D207_PRED, - RD_D63_PRED = D63_PRED, - RD_TM_PRED = TM_PRED, - RD_NEARESTMV = NEARESTMV, - RD_NEARMV = NEARMV, - RD_ZEROMV = ZEROMV, - RD_NEWMV = NEWMV, - RD_I4X4_PRED, - RD_SPLITMV, - RD_MODE_COUNT -} RD_PREDICTION_MODE; - typedef struct { - RD_PREDICTION_MODE mode; + MB_PREDICTION_MODE mode; MV_REFERENCE_FRAME ref_frame; MV_REFERENCE_FRAME second_ref_frame; } MODE_DEFINITION; +typedef struct { + MV_REFERENCE_FRAME ref_frame; + MV_REFERENCE_FRAME second_ref_frame; +} REF_DEFINITION; + struct optimize_ctx { ENTROPY_CONTEXT ta[MAX_MB_PLANE][16]; ENTROPY_CONTEXT tl[MAX_MB_PLANE][16]; -- cgit v1.2.3