int8_t *mb_transform_size; /* transform_size_8x8_flag of each mb */
uint16_t *slice_table; /* sh->first_mb of the slice that the indexed mb is part of
* NOTE: this will fail on resolutions above 2^16 MBs... */
+ uint8_t *field;
/* buffer for weighted versions of the reference frames */
pixel *p_weight_buf[X264_REF_MAX];
frame->i_stride[0] * (frame->i_lines[0] + 2*i_padv) * sizeof(uint16_t) << h->frames.b_have_sub8x8_esa );
frame->integral = (uint16_t*)frame->buffer[3] + frame->i_stride[0] * i_padv + PADH;
}
+ if( h->param.b_interlaced )
+ CHECKED_MALLOC( frame->field, i_mb_count * sizeof(uint8_t) );
}
else /* fenc frame */
{
x264_free( frame->i_inv_qscale_factor );
x264_free( frame->i_row_bits );
x264_free( frame->f_row_qp );
+ x264_free( frame->field );
x264_free( frame->mb_type );
x264_free( frame->mb_partition );
x264_free( frame->mv[0] );
int16_t (*mv[2])[2];
int16_t (*mv16x16)[2];
int16_t (*lowres_mvs[2][X264_BFRAME_MAX+1])[2];
+ uint8_t *field;
/* Stored as (lists_used << LOWRES_COST_SHIFT) + (cost).
* Doesn't need special addressing for intra cost because
h->mb.ref[1] = h->fdec->ref[1];
h->mb.type = h->fdec->mb_type;
h->mb.partition = h->fdec->mb_partition;
+ h->mb.field = h->fdec->field;
h->fdec->i_ref[0] = h->i_ref[0];
h->fdec->i_ref[1] = h->i_ref[1];
if( i_mb_x == 0 && !h->mb.b_reencode_mb )
x264_fdec_filter_row( h, i_mb_y, 1 );
+ if( h->param.b_interlaced )
+ {
+ if( !(i_mb_y&1) )
+ h->mb.b_interlaced = 1;
+ x264_zigzag_init( h->param.cpu, &h->zigzagf, h->mb.b_interlaced );
+ h->mb.field[mb_xy] = h->mb.b_interlaced;
+ }
+
/* load cache */
x264_macroblock_cache_load( h, i_mb_x, i_mb_y );