pts_set_framerate(&priv->tsg, priv->fps_n, priv->fps_d);
gst_vaapi_decoder_set_framerate(base_decoder, priv->fps_n, priv->fps_d);
- if (gst_mpeg_video_finalise_mpeg2_sequence_header(seq_hdr, NULL, NULL))
- gst_vaapi_decoder_set_pixel_aspect_ratio(base_decoder,
- seq_hdr->par_w, seq_hdr->par_h);
-
priv->width = seq_hdr->width;
priv->height = seq_hdr->height;
priv->size_changed = TRUE;
{
GstVaapiDecoder * const base_decoder = GST_VAAPI_DECODER(decoder);
GstVaapiDecoderMpeg2Private * const priv = decoder->priv;
- GstMpegVideoSequenceHdr * const seq_hdr = &priv->seq_hdr_unit->data.seq_hdr;
GstMpegVideoSequenceExt *seq_ext;
GstVaapiProfile profile;
guint width, height;
priv->profile = profile;
priv->profile_changed = TRUE;
}
-
- if (gst_mpeg_video_finalise_mpeg2_sequence_header(seq_hdr, seq_ext, NULL))
- gst_vaapi_decoder_set_pixel_aspect_ratio(base_decoder,
- seq_hdr->par_w, seq_hdr->par_h);
-
return GST_VAAPI_DECODER_STATUS_SUCCESS;
}
GstVaapiDecoderMpeg2 * const decoder =
GST_VAAPI_DECODER_MPEG2(base_decoder);
GstVaapiDecoderMpeg2Private * const priv = decoder->priv;
+ GstMpegVideoSequenceHdr *seq_hdr;
+ GstMpegVideoSequenceExt *seq_ext;
+ GstMpegVideoSequenceDisplayExt *seq_display_ext;
GstVaapiPicture *picture;
GstVaapiDecoderStatus status;
return GST_VAAPI_DECODER_STATUS_SUCCESS;
}
+ seq_hdr = &priv->seq_hdr_unit->data.seq_hdr;
+ seq_ext = priv->seq_ext_unit ? &priv->seq_ext_unit->data.seq_ext : NULL;
+ seq_display_ext = priv->seq_display_ext_unit ?
+ &priv->seq_display_ext_unit->data.seq_display_ext : NULL;
+ if (gst_mpeg_video_finalise_mpeg2_sequence_header(seq_hdr, seq_ext,
+ seq_display_ext))
+ gst_vaapi_decoder_set_pixel_aspect_ratio(base_decoder,
+ seq_hdr->par_w, seq_hdr->par_h);
+
status = ensure_context(decoder);
if (status != GST_VAAPI_DECODER_STATUS_SUCCESS) {
GST_ERROR("failed to reset context");