diff options
Diffstat (limited to 'vp8/encoder/pickinter.c')
-rw-r--r-- | vp8/encoder/pickinter.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/vp8/encoder/pickinter.c b/vp8/encoder/pickinter.c index 77d9152eb..b67f04b85 100644 --- a/vp8/encoder/pickinter.c +++ b/vp8/encoder/pickinter.c @@ -151,7 +151,7 @@ static int pick_intra4x4block( unsigned char *yleft = dst - 1; unsigned char top_left = Above[-1]; - for (mode = B_DC_PRED; mode <= B_HE_PRED /*B_HU_PRED*/; mode++) + for (mode = B_DC_PRED; mode <= B_HE_PRED; mode++) { int this_rd; @@ -171,7 +171,7 @@ static int pick_intra4x4block( } } - b->bmi.as_mode = (B_PREDICTION_MODE)(*best_mode); + b->bmi.as_mode = *best_mode; vp8_encode_intra4x4block(x, ib); return best_rd; } @@ -458,7 +458,15 @@ void get_lower_res_motion_info(VP8_COMP *cpi, MACROBLOCKD *xd, int *dissim, static void check_for_encode_breakout(unsigned int sse, MACROBLOCK* x) { - if (sse < x->encode_breakout) + MACROBLOCKD *xd = &x->e_mbd; + + unsigned int threshold = (xd->block[0].dequant[1] + * xd->block[0].dequant[1] >>4); + + if(threshold < x->encode_breakout) + threshold = x->encode_breakout; + + if (sse < threshold ) { /* Check u and v to make sure skip is ok */ unsigned int sse2 = 0; |