summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-07-31 08:01:29 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-07-31 08:01:29 +0000
commit5efa265074d631d39ed7ffb25bcb4d951e2f395a (patch)
treec8091e60a9ca40ab70f4a3b6669d465c396b881a
parent57d2bce188abbd0ed2e5beb58bcff3cd40e8d8bd (diff)
b frame direct mode bugfix (bug found by CM <chenm001 at 163 dot com>)
Originally committed as revision 832 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavcodec/motion_est.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/motion_est.c b/libavcodec/motion_est.c
index 21d1a74cb8..ffc251da70 100644
--- a/libavcodec/motion_est.c
+++ b/libavcodec/motion_est.c
@@ -1434,7 +1434,7 @@ static inline int direct_search(MpegEncContext * s,
const int time_pb= time_pp - time_bp;
int bx, by;
int mx, my, mx2, my2;
- uint8_t *ref_picture= s->me_scratchpad - (mb_x + 1 + (mb_y + 1)*s->linesize)*16;
+ uint8_t *ref_picture= s->me_scratchpad - (mb_x - 1 + (mb_y - 1)*s->linesize)*16;
int16_t (*mv_table)[2]= s->b_direct_mv_table;
uint16_t *mv_penalty= s->mv_penalty[s->f_code] + MAX_MV; // f_code of the prev frame