aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorshahriman AMS <shahriman_ams@yahoo.com>2011-11-08 08:51:45 +0000
committerAnton Khirnov <anton@khirnov.net>2011-11-09 11:00:49 +0100
commitc33d4916fba4e81a520b0a579cfb5c3b7c7cf9c7 (patch)
tree210539cfd818b05d45696eb8ae06f8cfe9009dbc
parent62622d04eb515c792e871e1cc9f5de66531b775c (diff)
downloadffmpeg-c33d4916fba4e81a520b0a579cfb5c3b7c7cf9c7.tar.gz
VC1: Add bottom field offset to block_index[] to avoid rewriting (+10L)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
-rw-r--r--libavcodec/vc1dec.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libavcodec/vc1dec.c b/libavcodec/vc1dec.c
index 4f366b8aa8..7a65f31826 100644
--- a/libavcodec/vc1dec.c
+++ b/libavcodec/vc1dec.c
@@ -930,8 +930,8 @@ static void vc1_mc_4mv_chroma(VC1Context *v, int dir)
if (!v->field_mode || (v->field_mode && !v->numref)) {
valid_count = get_chroma_mv(mvx, mvy, intra, 0, &tx, &ty);
if (!valid_count) {
- s->current_picture.f.motion_val[1][s->block_index[0]][0] = 0;
- s->current_picture.f.motion_val[1][s->block_index[0]][1] = 0;
+ s->current_picture.f.motion_val[1][s->block_index[0] + v->blocks_off][0] = 0;
+ s->current_picture.f.motion_val[1][s->block_index[0] + v->blocks_off][1] = 0;
v->luma_mv[s->mb_x][0] = v->luma_mv[s->mb_x][1] = 0;
return; //no need to do MC for intra blocks
}
@@ -943,8 +943,8 @@ static void vc1_mc_4mv_chroma(VC1Context *v, int dir)
if (dominant)
chroma_ref_type = !v->cur_field_type;
}
- s->current_picture.f.motion_val[1][s->block_index[0]][0] = tx;
- s->current_picture.f.motion_val[1][s->block_index[0]][1] = ty;
+ s->current_picture.f.motion_val[1][s->block_index[0] + v->blocks_off][0] = tx;
+ s->current_picture.f.motion_val[1][s->block_index[0] + v->blocks_off][1] = ty;
uvmx = (tx + ((tx & 3) == 3)) >> 1;
uvmy = (ty + ((ty & 3) == 3)) >> 1;