@ -59,9 +59,9 @@ static inline void init_block_index(VC1Context *v)
MpegEncContext * s = & v - > s ;
ff_init_block_index ( s ) ;
if ( v - > field_mode & & ! ( v - > second_field ^ v - > tff ) ) {
s - > dest [ 0 ] + = s - > current _picture _ptr - > f - > linesize [ 0 ] ;
s - > dest [ 1 ] + = s - > current _picture _ptr - > f - > linesize [ 1 ] ;
s - > dest [ 2 ] + = s - > current _picture _ptr - > f - > linesize [ 2 ] ;
s - > dest [ 0 ] + = s - > cur_pic_ptr - > f - > linesize [ 0 ] ;
s - > dest [ 1 ] + = s - > cur_pic_ptr - > f - > linesize [ 1 ] ;
s - > dest [ 2 ] + = s - > cur_pic_ptr - > f - > linesize [ 2 ] ;
}
}
@ -417,7 +417,7 @@ static inline int ff_vc1_pred_dc(MpegEncContext *s, int overlap, int pq, int n,
int dqscale_index ;
/* scale predictors if needed */
q1 = FFABS ( s - > current _picture . qscale_table [ mb_pos ] ) ;
q1 = FFABS ( s - > cur_pic . qscale_table [ mb_pos ] ) ;
dqscale_index = s - > y_dc_scale_table [ q1 ] - 1 ;
if ( dqscale_index < 0 )
return 0 ;
@ -433,12 +433,12 @@ static inline int ff_vc1_pred_dc(MpegEncContext *s, int overlap, int pq, int n,
a = dc_val [ - wrap ] ;
if ( c_avail & & ( n ! = 1 & & n ! = 3 ) ) {
q2 = FFABS ( s - > current _picture . qscale_table [ mb_pos - 1 ] ) ;
q2 = FFABS ( s - > cur_pic . qscale_table [ mb_pos - 1 ] ) ;
if ( q2 & & q2 ! = q1 )
c = ( int ) ( ( unsigned ) c * s - > y_dc_scale_table [ q2 ] * ff_vc1_dqscale [ dqscale_index ] + 0x20000 ) > > 18 ;
}
if ( a_avail & & ( n ! = 2 & & n ! = 3 ) ) {
q2 = FFABS ( s - > current _picture . qscale_table [ mb_pos - s - > mb_stride ] ) ;
q2 = FFABS ( s - > cur_pic . qscale_table [ mb_pos - s - > mb_stride ] ) ;
if ( q2 & & q2 ! = q1 )
a = ( int ) ( ( unsigned ) a * s - > y_dc_scale_table [ q2 ] * ff_vc1_dqscale [ dqscale_index ] + 0x20000 ) > > 18 ;
}
@ -448,7 +448,7 @@ static inline int ff_vc1_pred_dc(MpegEncContext *s, int overlap, int pq, int n,
off - - ;
if ( n ! = 2 )
off - = s - > mb_stride ;
q2 = FFABS ( s - > current _picture . qscale_table [ off ] ) ;
q2 = FFABS ( s - > cur_pic . qscale_table [ off ] ) ;
if ( q2 & & q2 ! = q1 )
b = ( int ) ( ( unsigned ) b * s - > y_dc_scale_table [ q2 ] * ff_vc1_dqscale [ dqscale_index ] + 0x20000 ) > > 18 ;
}
@ -771,19 +771,19 @@ static int vc1_decode_i_block_adv(VC1Context *v, int16_t block[64], int n,
else // top
ac_val - = 16 * s - > block_wrap [ n ] ;
q1 = s - > current _picture . qscale_table [ mb_pos ] ;
q1 = s - > cur_pic . qscale_table [ mb_pos ] ;
if ( n = = 3 )
q2 = q1 ;
else if ( dc_pred_dir ) {
if ( n = = 1 )
q2 = q1 ;
else if ( c_avail & & mb_pos )
q2 = s - > current _picture . qscale_table [ mb_pos - 1 ] ;
q2 = s - > cur_pic . qscale_table [ mb_pos - 1 ] ;
} else {
if ( n = = 2 )
q2 = q1 ;
else if ( a_avail & & mb_pos > = s - > mb_stride )
q2 = s - > current _picture . qscale_table [ mb_pos - s - > mb_stride ] ;
q2 = s - > cur_pic . qscale_table [ mb_pos - s - > mb_stride ] ;
}
//AC Decoding
@ -973,11 +973,11 @@ static int vc1_decode_intra_block(VC1Context *v, int16_t block[64], int n,
else //top
ac_val - = 16 * s - > block_wrap [ n ] ;
q1 = s - > current _picture . qscale_table [ mb_pos ] ;
q1 = s - > cur_pic . qscale_table [ mb_pos ] ;
if ( dc_pred_dir & & c_avail & & mb_pos )
q2 = s - > current _picture . qscale_table [ mb_pos - 1 ] ;
q2 = s - > cur_pic . qscale_table [ mb_pos - 1 ] ;
if ( ! dc_pred_dir & & a_avail & & mb_pos > = s - > mb_stride )
q2 = s - > current _picture . qscale_table [ mb_pos - s - > mb_stride ] ;
q2 = s - > cur_pic . qscale_table [ mb_pos - s - > mb_stride ] ;
if ( dc_pred_dir & & n = = 1 )
q2 = q1 ;
if ( ! dc_pred_dir & & n = = 2 )
@ -1314,10 +1314,10 @@ static int vc1_decode_p_mb(VC1Context *v)
GET_MVDATA ( dmv_x , dmv_y ) ;
if ( s - > mb_intra ) {
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = 0 ;
}
s - > current _picture . mb_type [ mb_pos ] = s - > mb_intra ? MB_TYPE_INTRA : MB_TYPE_16x16 ;
s - > cur_pic . mb_type [ mb_pos ] = s - > mb_intra ? MB_TYPE_INTRA : MB_TYPE_16x16 ;
ff_vc1_pred_mv ( v , 0 , dmv_x , dmv_y , 1 , v - > range_x , v - > range_y , v - > mb_type [ 0 ] , 0 , 0 ) ;
/* FIXME Set DC val for inter block ? */
@ -1334,7 +1334,7 @@ static int vc1_decode_p_mb(VC1Context *v)
mquant = v - > pq ;
cbp = 0 ;
}
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & ! s - > mb_intra & & mb_has_coeffs )
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] ,
@ -1383,8 +1383,8 @@ static int vc1_decode_p_mb(VC1Context *v)
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
s - > dc_val [ 0 ] [ s - > block_index [ i ] ] = 0 ;
}
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
ff_vc1_pred_mv ( v , 0 , 0 , 0 , 1 , v - > range_x , v - > range_y , v - > mb_type [ 0 ] , 0 , 0 ) ;
ff_vc1_mc_1mv ( v , 0 ) ;
}
@ -1427,7 +1427,7 @@ static int vc1_decode_p_mb(VC1Context *v)
if ( ! intra_count & & ! coded_inter )
goto end ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* test if block is intra and has pred */
{
int intrapred = 0 ;
@ -1484,7 +1484,7 @@ static int vc1_decode_p_mb(VC1Context *v)
}
} else { // skipped MB
s - > mb_intra = 0 ;
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
for ( i = 0 ; i < 6 ; i + + ) {
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
s - > dc_val [ 0 ] [ s - > block_index [ i ] ] = 0 ;
@ -1494,7 +1494,7 @@ static int vc1_decode_p_mb(VC1Context *v)
ff_vc1_mc_4mv_luma ( v , i , 0 , 0 ) ;
}
ff_vc1_mc_4mv_chroma ( v , 0 ) ;
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
}
}
end :
@ -1574,19 +1574,19 @@ static int vc1_decode_p_mb_intfr(VC1Context *v)
}
if ( ff_vc1_mbmode_intfrp [ v - > fourmvswitch ] [ idx_mbmode ] [ 0 ] = = MV_PMODE_INTFR_INTRA ) { // intra MB
for ( i = 0 ; i < 4 ; i + + ) {
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
}
v - > is_intra [ s - > mb_x ] = 0x3f ; // Set the bitfield to all 1.
s - > mb_intra = 1 ;
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
fieldtx = v - > fieldtx_plane [ mb_pos ] = get_bits1 ( gb ) ;
mb_has_coeffs = get_bits1 ( gb ) ;
if ( mb_has_coeffs )
cbp = 1 + get_vlc2 ( & v - > s . gb , v - > cbpcy_vlc , VC1_CBPCY_P_VLC_BITS , 2 ) ;
v - > s . ac_pred = v - > acpred_plane [ mb_pos ] = get_bits1 ( gb ) ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* Set DC scale - y and c use the same (not sure if necessary here) */
s - > y_dc_scale = s - > y_dc_scale_table [ FFABS ( mquant ) ] ;
s - > c_dc_scale = s - > c_dc_scale_table [ FFABS ( mquant ) ] ;
@ -1666,7 +1666,7 @@ static int vc1_decode_p_mb_intfr(VC1Context *v)
}
if ( cbp )
GET_MQUANT ( ) ; // p. 227
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & cbp )
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
for ( i = 0 ; i < 6 ; i + + ) {
@ -1697,8 +1697,8 @@ static int vc1_decode_p_mb_intfr(VC1Context *v)
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
s - > dc_val [ 0 ] [ s - > block_index [ i ] ] = 0 ;
}
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 0 ] ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 1 ] ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 2 ] ] = 0 ;
@ -1742,11 +1742,11 @@ static int vc1_decode_p_mb_intfi(VC1Context *v)
if ( idx_mbmode < = 1 ) { // intra MB
v - > is_intra [ s - > mb_x ] = 0x3f ; // Set the bitfield to all 1.
s - > mb_intra = 1 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] + v - > blocks_off ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] + v - > blocks_off ] [ 1 ] = 0 ;
s - > current _picture . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] + v - > blocks_off ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] + v - > blocks_off ] [ 1 ] = 0 ;
s - > cur_pic . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* Set DC scale - y and c use the same (not sure if necessary here) */
s - > y_dc_scale = s - > y_dc_scale_table [ FFABS ( mquant ) ] ;
s - > c_dc_scale = s - > c_dc_scale_table [ FFABS ( mquant ) ] ;
@ -1775,7 +1775,7 @@ static int vc1_decode_p_mb_intfi(VC1Context *v)
}
} else {
s - > mb_intra = v - > is_intra [ s - > mb_x ] = 0 ;
s - > current _picture . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_16x16 ;
s - > cur_pic . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_16x16 ;
for ( i = 0 ; i < 6 ; i + + )
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
if ( idx_mbmode < = 5 ) { // 1-MV
@ -1803,7 +1803,7 @@ static int vc1_decode_p_mb_intfi(VC1Context *v)
if ( cbp ) {
GET_MQUANT ( ) ;
}
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & cbp ) {
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
}
@ -1875,7 +1875,7 @@ static int vc1_decode_b_mb(VC1Context *v)
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
s - > dc_val [ 0 ] [ s - > block_index [ i ] ] = 0 ;
}
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
if ( ! direct ) {
if ( ! skipped ) {
@ -1912,7 +1912,7 @@ static int vc1_decode_b_mb(VC1Context *v)
cbp = get_vlc2 ( & v - > s . gb , v - > cbpcy_vlc , VC1_CBPCY_P_VLC_BITS , 2 ) ;
GET_MQUANT ( ) ;
s - > mb_intra = 0 ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf )
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
dmv_x [ 0 ] = dmv_y [ 0 ] = dmv_x [ 1 ] = dmv_y [ 1 ] = 0 ;
@ -1927,7 +1927,7 @@ static int vc1_decode_b_mb(VC1Context *v)
}
if ( s - > mb_intra & & ! mb_has_coeffs ) {
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
s - > ac_pred = get_bits1 ( gb ) ;
cbp = 0 ;
ff_vc1_pred_b_mv ( v , dmv_x , dmv_y , direct , bmvtype ) ;
@ -1949,7 +1949,7 @@ static int vc1_decode_b_mb(VC1Context *v)
s - > ac_pred = get_bits1 ( gb ) ;
cbp = get_vlc2 ( & v - > s . gb , v - > cbpcy_vlc , VC1_CBPCY_P_VLC_BITS , 2 ) ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & ! s - > mb_intra & & mb_has_coeffs )
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
}
@ -2024,11 +2024,11 @@ static int vc1_decode_b_mb_intfi(VC1Context *v)
if ( idx_mbmode < = 1 ) { // intra MB
v - > is_intra [ s - > mb_x ] = 0x3f ; // Set the bitfield to all 1.
s - > mb_intra = 1 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = 0 ;
s - > current _picture . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = 0 ;
s - > cur_pic . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* Set DC scale - y and c use the same (not sure if necessary here) */
s - > y_dc_scale = s - > y_dc_scale_table [ FFABS ( mquant ) ] ;
s - > c_dc_scale = s - > c_dc_scale_table [ FFABS ( mquant ) ] ;
@ -2064,7 +2064,7 @@ static int vc1_decode_b_mb_intfi(VC1Context *v)
}
} else {
s - > mb_intra = v - > is_intra [ s - > mb_x ] = 0 ;
s - > current _picture . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_16x16 ;
s - > cur_pic . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_16x16 ;
for ( i = 0 ; i < 6 ; i + + )
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
if ( v - > fmb_is_raw )
@ -2101,7 +2101,7 @@ static int vc1_decode_b_mb_intfi(VC1Context *v)
if ( bmvtype = = BMV_TYPE_DIRECT ) {
dmv_x [ 0 ] = dmv_y [ 0 ] = pred_flag [ 0 ] = 0 ;
dmv_x [ 1 ] = dmv_y [ 1 ] = pred_flag [ 0 ] = 0 ;
if ( ! s - > next_picture _ptr - > field_picture ) {
if ( ! s - > next_pic_ptr - > field_picture ) {
av_log ( s - > avctx , AV_LOG_ERROR , " Mixed field/frame direct mode not supported \n " ) ;
return AVERROR_INVALIDDATA ;
}
@ -2133,7 +2133,7 @@ static int vc1_decode_b_mb_intfi(VC1Context *v)
if ( cbp ) {
GET_MQUANT ( ) ;
}
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & cbp ) {
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
}
@ -2212,21 +2212,21 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
if ( ff_vc1_mbmode_intfrp [ 0 ] [ idx_mbmode ] [ 0 ] = = MV_PMODE_INTFR_INTRA ) { // intra MB
for ( i = 0 ; i < 4 ; i + + ) {
s - > mv [ 0 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
s - > mv [ 0 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
}
v - > is_intra [ s - > mb_x ] = 0x3f ; // Set the bitfield to all 1.
s - > mb_intra = 1 ;
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
fieldtx = v - > fieldtx_plane [ mb_pos ] = get_bits1 ( gb ) ;
mb_has_coeffs = get_bits1 ( gb ) ;
if ( mb_has_coeffs )
cbp = 1 + get_vlc2 ( & v - > s . gb , v - > cbpcy_vlc , VC1_CBPCY_P_VLC_BITS , 2 ) ;
v - > s . ac_pred = v - > acpred_plane [ mb_pos ] = get_bits1 ( gb ) ;
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* Set DC scale - y and c use the same (not sure if necessary here) */
s - > y_dc_scale = s - > y_dc_scale_table [ FFABS ( mquant ) ] ;
s - > c_dc_scale = s - > c_dc_scale_table [ FFABS ( mquant ) ] ;
@ -2267,31 +2267,31 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
direct = v - > direct_mb_plane [ mb_pos ] ;
if ( direct ) {
if ( s - > next_picture _ptr - > field_picture )
if ( s - > next_pic_ptr - > field_picture )
av_log ( s - > avctx , AV_LOG_WARNING , " Mixed frame/field direct mode not supported \n " ) ;
s - > mv [ 0 ] [ 0 ] [ 0 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ 0 ] ] [ 0 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 0 ] [ 1 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ 0 ] ] [ 1 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 0 ] [ 0 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 0 ] [ 1 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 0 ] [ 0 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ 0 ] ] [ 0 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 0 ] [ 1 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ 0 ] ] [ 1 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 0 ] [ 0 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 0 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 0 ] [ 1 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 0 ] ] [ 1 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
if ( twomv ) {
s - > mv [ 0 ] [ 2 ] [ 0 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ 2 ] ] [ 0 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 2 ] [ 1 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ 2 ] ] [ 1 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 2 ] [ 0 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 2 ] [ 1 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] = scale_mv ( s - > next_picture . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 2 ] [ 0 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ 2 ] ] [ 0 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 0 ] [ 2 ] [ 1 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ 2 ] ] [ 1 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] , v - > bfraction , 0 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 2 ] [ 0 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 0 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
s - > mv [ 1 ] [ 2 ] [ 1 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] = scale_mv ( s - > next_pic . motion_val [ 1 ] [ s - > block_index [ 2 ] ] [ 1 ] , v - > bfraction , 1 , s - > quarter_sample ) ;
for ( i = 1 ; i < 4 ; i + = 2 ) {
s - > mv [ 0 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 0 ] [ i - 1 ] [ 0 ] ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 0 ] [ i - 1 ] [ 1 ] ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 1 ] [ i - 1 ] [ 0 ] ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 1 ] [ i - 1 ] [ 1 ] ;
s - > mv [ 0 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 0 ] [ i - 1 ] [ 0 ] ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 0 ] [ i - 1 ] [ 1 ] ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 1 ] [ i - 1 ] [ 0 ] ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 1 ] [ i - 1 ] [ 1 ] ;
}
} else {
for ( i = 1 ; i < 4 ; i + + ) {
s - > mv [ 0 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 0 ] [ 0 ] [ 0 ] ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 0 ] [ 0 ] [ 1 ] ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 1 ] [ 0 ] [ 0 ] ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 1 ] [ 0 ] [ 1 ] ;
s - > mv [ 0 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 0 ] [ 0 ] [ 0 ] ;
s - > mv [ 0 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 0 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 0 ] [ 0 ] [ 1 ] ;
s - > mv [ 1 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = s - > mv [ 1 ] [ 0 ] [ 0 ] ;
s - > mv [ 1 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = s - > mv [ 1 ] [ 0 ] [ 1 ] ;
}
}
}
@ -2393,10 +2393,10 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
if ( mvsw ) {
for ( i = 0 ; i < 2 ; i + + ) {
s - > mv [ dir ] [ i + 2 ] [ 0 ] = s - > mv [ dir ] [ i ] [ 0 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ dir ] [ i + 2 ] [ 1 ] = s - > mv [ dir ] [ i ] [ 1 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 0 ] = s - > mv [ dir2 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 0 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 0 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 1 ] = s - > mv [ dir2 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 1 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 1 ] ;
s - > mv [ dir ] [ i + 2 ] [ 0 ] = s - > mv [ dir ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ dir ] [ i + 2 ] [ 1 ] = s - > mv [ dir ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 0 ] = s - > mv [ dir2 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 0 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 0 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 1 ] = s - > mv [ dir2 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 1 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 1 ] ;
}
} else {
ff_vc1_pred_mv_intfr ( v , 0 , 0 , 0 , 2 , v - > range_x , v - > range_y , ! dir ) ;
@ -2423,15 +2423,15 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
v - > blk_mv_type [ s - > block_index [ 3 ] ] = 1 ;
ff_vc1_pred_mv_intfr ( v , 0 , 0 , 0 , 2 , v - > range_x , v - > range_y , ! dir ) ;
for ( i = 0 ; i < 2 ; i + + ) {
s - > mv [ ! dir ] [ i + 2 ] [ 0 ] = s - > mv [ ! dir ] [ i ] [ 0 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 1 ] = s - > mv [ ! dir ] [ i ] [ 1 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 0 ] = s - > mv [ ! dir ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 1 ] = s - > mv [ ! dir ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 1 ] ;
}
ff_vc1_mc_1mv ( v , dir ) ;
}
if ( cbp )
GET_MQUANT ( ) ; // p. 227
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
if ( ! v - > ttmbf & & cbp )
ttmb = get_vlc2 ( gb , ff_vc1_ttmb_vlc [ v - > tt_index ] , VC1_TTMB_VLC_BITS , 2 ) ;
for ( i = 0 ; i < 6 ; i + + ) {
@ -2462,8 +2462,8 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
v - > mb_type [ 0 ] [ s - > block_index [ i ] ] = 0 ;
s - > dc_val [ 0 ] [ s - > block_index [ i ] ] = 0 ;
}
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > current _picture . qscale_table [ mb_pos ] = 0 ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_SKIP ;
s - > cur_pic . qscale_table [ mb_pos ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 0 ] ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 1 ] ] = 0 ;
v - > blk_mv_type [ s - > block_index [ 2 ] ] = 0 ;
@ -2481,10 +2481,10 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
if ( mvsw )
dir2 = ! dir ;
for ( i = 0 ; i < 2 ; i + + ) {
s - > mv [ dir ] [ i + 2 ] [ 0 ] = s - > mv [ dir ] [ i ] [ 0 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ dir ] [ i + 2 ] [ 1 ] = s - > mv [ dir ] [ i ] [ 1 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > current _picture . motion_val [ dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 0 ] = s - > mv [ dir2 ] [ i ] [ 0 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 0 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 0 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 1 ] = s - > mv [ dir2 ] [ i ] [ 1 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 1 ] = s - > current _picture . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 1 ] ;
s - > mv [ dir ] [ i + 2 ] [ 0 ] = s - > mv [ dir ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ dir ] [ i + 2 ] [ 1 ] = s - > mv [ dir ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > cur_pic . motion_val [ dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 0 ] = s - > mv [ dir2 ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 0 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 0 ] ;
s - > mv [ dir2 ] [ i + 2 ] [ 1 ] = s - > mv [ dir2 ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i ] ] [ 1 ] = s - > cur_pic . motion_val [ dir2 ] [ s - > block_index [ i + 2 ] ] [ 1 ] ;
}
} else {
v - > blk_mv_type [ s - > block_index [ 0 ] ] = 1 ;
@ -2493,8 +2493,8 @@ static int vc1_decode_b_mb_intfr(VC1Context *v)
v - > blk_mv_type [ s - > block_index [ 3 ] ] = 1 ;
ff_vc1_pred_mv_intfr ( v , 0 , 0 , 0 , 2 , v - > range_x , v - > range_y , ! dir ) ;
for ( i = 0 ; i < 2 ; i + + ) {
s - > mv [ ! dir ] [ i + 2 ] [ 0 ] = s - > mv [ ! dir ] [ i ] [ 0 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 1 ] = s - > mv [ ! dir ] [ i ] [ 1 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > current _picture . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 1 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 0 ] = s - > mv [ ! dir ] [ i ] [ 0 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 0 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 0 ] ;
s - > mv [ ! dir ] [ i + 2 ] [ 1 ] = s - > mv [ ! dir ] [ i ] [ 1 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i + 2 ] ] [ 1 ] = s - > cur_pic . motion_val [ ! dir ] [ s - > block_index [ i ] ] [ 1 ] ;
}
}
}
@ -2563,11 +2563,11 @@ static void vc1_decode_i_blocks(VC1Context *v)
update_block_index ( s ) ;
s - > bdsp . clear_blocks ( v - > block [ v - > cur_blk_idx ] [ 0 ] ) ;
mb_pos = s - > mb_x + s - > mb_y * s - > mb_width ;
s - > current _picture . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
s - > current _picture . qscale_table [ mb_pos ] = v - > pq ;
s - > cur_pic . mb_type [ mb_pos ] = MB_TYPE_INTRA ;
s - > cur_pic . qscale_table [ mb_pos ] = v - > pq ;
for ( int i = 0 ; i < 4 ; i + + ) {
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] ] [ 1 ] = 0 ;
}
// do actual MB decoding and displaying
@ -2693,10 +2693,10 @@ static int vc1_decode_i_blocks_adv(VC1Context *v)
update_block_index ( s ) ;
s - > bdsp . clear_blocks ( v - > block [ v - > cur_blk_idx ] [ 0 ] ) ;
mb_pos = s - > mb_x + s - > mb_y * s - > mb_stride ;
s - > current _picture . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
s - > cur_pic . mb_type [ mb_pos + v - > mb_off ] = MB_TYPE_INTRA ;
for ( int i = 0 ; i < 4 ; i + + ) {
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] + v - > blocks_off ] [ 0 ] = 0 ;
s - > current _picture . motion_val [ 1 ] [ s - > block_index [ i ] + v - > blocks_off ] [ 1 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] + v - > blocks_off ] [ 0 ] = 0 ;
s - > cur_pic . motion_val [ 1 ] [ s - > block_index [ i ] + v - > blocks_off ] [ 1 ] = 0 ;
}
// do actual MB decoding and displaying
@ -2719,7 +2719,7 @@ static int vc1_decode_i_blocks_adv(VC1Context *v)
GET_MQUANT ( ) ;
s - > current _picture . qscale_table [ mb_pos ] = mquant ;
s - > cur_pic . qscale_table [ mb_pos ] = mquant ;
/* Set DC scale - y and c use the same */
s - > y_dc_scale = s - > y_dc_scale_table [ FFABS ( mquant ) ] ;
s - > c_dc_scale = s - > c_dc_scale_table [ FFABS ( mquant ) ] ;
@ -2943,7 +2943,7 @@ static void vc1_decode_skip_blocks(VC1Context *v)
{
MpegEncContext * s = & v - > s ;
if ( ! v - > s . last_picture . f - > data [ 0 ] )
if ( ! v - > s . last_pic . f - > data [ 0 ] )
return ;
ff_er_add_slice ( & s - > er , 0 , s - > start_mb_y , s - > mb_width - 1 , s - > end_mb_y - 1 , ER_MB_END ) ;
@ -2952,9 +2952,9 @@ static void vc1_decode_skip_blocks(VC1Context *v)
s - > mb_x = 0 ;
init_block_index ( v ) ;
update_block_index ( s ) ;
memcpy ( s - > dest [ 0 ] , s - > last_picture . f - > data [ 0 ] + s - > mb_y * 16 * s - > linesize , s - > linesize * 16 ) ;
memcpy ( s - > dest [ 1 ] , s - > last_picture . f - > data [ 1 ] + s - > mb_y * 8 * s - > uvlinesize , s - > uvlinesize * 8 ) ;
memcpy ( s - > dest [ 2 ] , s - > last_picture . f - > data [ 2 ] + s - > mb_y * 8 * s - > uvlinesize , s - > uvlinesize * 8 ) ;
memcpy ( s - > dest [ 0 ] , s - > last_pic . f - > data [ 0 ] + s - > mb_y * 16 * s - > linesize , s - > linesize * 16 ) ;
memcpy ( s - > dest [ 1 ] , s - > last_pic . f - > data [ 1 ] + s - > mb_y * 8 * s - > uvlinesize , s - > uvlinesize * 8 ) ;
memcpy ( s - > dest [ 2 ] , s - > last_pic . f - > data [ 2 ] + s - > mb_y * 8 * s - > uvlinesize , s - > uvlinesize * 8 ) ;
s - > first_slice_line = 0 ;
}
}
@ -2964,7 +2964,7 @@ void ff_vc1_decode_blocks(VC1Context *v)
v - > s . esc3_level_length = 0 ;
if ( v - > x8_type ) {
ff_intrax8_decode_picture ( & v - > x8 , & v - > s . current _picture ,
ff_intrax8_decode_picture ( & v - > x8 , & v - > s . cur_pic ,
& v - > s . gb , & v - > s . mb_x , & v - > s . mb_y ,
2 * v - > pq + v - > halfpq , v - > pq * ! v - > pquantizer ,
v - > s . loop_filter , v - > s . low_delay ) ;