+ if( p_sys->p_info->sequence->flags & SEQ_FLAG_LOW_DELAY ||
+ (p_sys->p_info->current_picture->flags &
+ PIC_MASK_CODING_TYPE) == PIC_FLAG_CODING_TYPE_B )
+ {
+ i_pts = p_block->i_dts;
+ }
+ }
+ p_block->i_pts = p_block->i_dts = 0;
+ /* End hack */
+
+#else /* New interface */
+
+ i_pts = p_sys->p_info->current_picture->flags & PIC_FLAG_TAGS ?
+ ( ( p_sys->p_info->current_picture->tag ==
+ (uint32_t)p_sys->i_current_pts ) ?
+ p_sys->i_current_pts : p_sys->i_previous_pts ) : 0;
+ i_dts = p_sys->p_info->current_picture->flags & PIC_FLAG_TAGS ?
+ ( ( p_sys->p_info->current_picture->tag2 ==
+ (uint32_t)p_sys->i_current_dts ) ?
+ p_sys->i_current_dts : p_sys->i_previous_dts ) : 0;
+#endif
+
+ /* If nb_fields == 1, it is a field picture, and it will be
+ * followed by another field picture for which we won't call
+ * vout_SynchroNewPicture() because this would have other
+ * problems, so we take it into account here.
+ * This kind of sucks, but I didn't think better. --Meuuh
+ */
+ vout_SynchroNewPicture( p_sys->p_synchro,
+ p_sys->p_info->current_picture->flags & PIC_MASK_CODING_TYPE,
+ p_sys->p_info->current_picture->nb_fields == 1 ? 2 :
+ p_sys->p_info->current_picture->nb_fields, i_pts, i_dts,
+ p_sys->i_current_rate,
+ p_sys->p_info->sequence->flags & SEQ_FLAG_LOW_DELAY );
+
+ if( !p_dec->b_pace_control && !p_sys->b_preroll &&
+ !(p_sys->b_slice_i
+ && ((p_sys->p_info->current_picture->flags
+ & PIC_MASK_CODING_TYPE) == P_CODING_TYPE))
+ && !vout_SynchroChoose( p_sys->p_synchro,
+ p_sys->p_info->current_picture->flags
+ & PIC_MASK_CODING_TYPE,
+ /*p_sys->p_vout->render_time*/ 0 /*FIXME*/,
+ p_sys->p_info->sequence->flags & SEQ_FLAG_LOW_DELAY ) )
+ {
+ mpeg2_skip( p_sys->p_mpeg2dec, 1 );
+ p_sys->b_skip = 1;
+ vout_SynchroTrash( p_sys->p_synchro );
+ mpeg2_set_buf( p_sys->p_mpeg2dec, buf, NULL );