mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 17:20:36 +00:00
codecs: mpeg2decoder: decode only if B and not closed gop
Mark as decode only if picture type is B, without previous picture in DBP and closed_gop is 0 as might be understood in "6.3.8 Group of pictures header". Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1939>
This commit is contained in:
parent
ec15caff93
commit
a926511df4
1 changed files with 5 additions and 0 deletions
|
@ -732,6 +732,11 @@ gst_mpeg2_decoder_start_current_picture (GstMpeg2Decoder * decoder,
|
|||
gst_mpeg2_dpb_get_neighbours (priv->dpb, priv->current_picture,
|
||||
&prev_picture, &next_picture);
|
||||
|
||||
if (priv->current_picture->type == GST_MPEG_VIDEO_PICTURE_TYPE_B
|
||||
&& !prev_picture && !priv->gop.closed_gop) {
|
||||
GST_VIDEO_CODEC_FRAME_FLAG_SET (priv->current_frame,
|
||||
GST_VIDEO_CODEC_FRAME_FLAG_DECODE_ONLY);
|
||||
}
|
||||
|
||||
ret = klass->start_picture (decoder, priv->current_picture, slice,
|
||||
prev_picture, next_picture);
|
||||
|
|
Loading…
Reference in a new issue