[Ffmpeg-cvslog] r5600 - trunk/libavcodec/vc1.c
kostya
subversion
Mon Jul 3 19:21:18 CEST 2006
Author: kostya
Date: Mon Jul 3 19:21:18 2006
New Revision: 5600
Modified:
trunk/libavcodec/vc1.c
Log:
4-MV mode final fixes (now it works for non-exotic modes)
Modified: trunk/libavcodec/vc1.c
==============================================================================
--- trunk/libavcodec/vc1.c (original)
+++ trunk/libavcodec/vc1.c Mon Jul 3 19:21:18 2006
@@ -1581,8 +1581,8 @@
/* Pullback MV as specified in 8.3.5.3.4 */
{
int qx, qy, X, Y;
- qx = s->mb_x << 6; //FIXME: add real block coords for 4MV mode
- qy = s->mb_y << 6;
+ qx = (s->mb_x << 6) + ((n==1 || n==3) ? 32 : 0);
+ qy = (s->mb_y << 6) + ((n==2 || n==3) ? 32 : 0);
X = (s->mb_width << 6) - 4;
Y = (s->mb_height << 6) - 4;
if(mv1) {
@@ -2516,7 +2516,9 @@
v->c_avail = v->mb_type[0][s->block_index[i] - 1];
vc1_decode_intra_block(v, s->block[i], i, is_coded[i], mquant, (i&4)?v->codingset2:v->codingset);
- //s->dsp.put_pixels_clamped(s->block[i], s->dest[dst_idx] + off, (i&4)?s->uvlinesize:s->linesize);
+ vc1_inv_trans(block[i], 8, 8);
+ for(j = 0; j < 64; j++) block[i][j] += 128;
+ s->dsp.put_pixels_clamped(s->block[i], s->dest[dst_idx] + off, (i&4)?s->uvlinesize:s->linesize);
/* TODO: proper loop filtering */
if(v->pq >= 9 && v->overlap) {
if(v->a_avail)
@@ -2528,20 +2530,21 @@
status = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, first_block);
if(!v->ttmbf && ttmb < 8) ttmb = -1;
first_block = 0;
- //s->dsp.add_pixels_clamped(s->block[i], s->dest[dst_idx] + off, (i&4)?s->uvlinesize:s->linesize);
+ s->dsp.add_pixels_clamped(s->block[i], s->dest[dst_idx] + off, (i&4)?s->uvlinesize:s->linesize);
}
}
return status;
}
else //Skipped MB
{
+ s->mb_intra = 0;
+ for (i=0; i<6; i++) v->mb_type[0][s->block_index[i]] = 0;
for (i=0; i<4; i++)
{
vc1_pred_mv(s, i, 0, 0, 0, v->range_x, v->range_y, v->mb_type[0]);
vc1_mc_4mv_luma(v, i);
}
vc1_mc_4mv_chroma(v);
- for(i = 0; i < 6; i++) v->mb_type[0][s->block_index[i]] = 0;
s->current_picture.qscale_table[mb_pos] = 0;
return 0;
}
More information about the ffmpeg-cvslog
mailing list