h265decoder: Set discont state after new_picture()

Subclass might negotiate with downstream inside of the new_picture().
Set discont state after the new_picture() call

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5368>
This commit is contained in:
Seungha Yang 2023-09-20 22:54:06 +09:00 committed by GStreamer Marge Bot
parent 87dcc7f7ad
commit 2b7dc0de1b

View file

@ -1842,14 +1842,6 @@ gst_h265_decoder_start_current_picture (GstH265Decoder * self)
return GST_FLOW_OK;
}
/* If subclass didn't update output state at this point,
* marking this picture as a discont and stores current input state */
if (priv->input_state_changed) {
gst_h265_picture_set_discont_state (priv->current_picture,
self->input_state);
priv->input_state_changed = FALSE;
}
if (!gst_h265_decoder_prepare_rps (self, &priv->current_slice,
priv->current_picture)) {
GST_WARNING_OBJECT (self, "Failed to prepare ref pic set");
@ -1887,6 +1879,14 @@ gst_h265_decoder_start_current_picture (GstH265Decoder * self)
}
}
/* If subclass didn't update output state at this point,
* marking this picture as a discont and stores current input state */
if (priv->input_state_changed) {
gst_h265_picture_set_discont_state (priv->current_picture,
self->input_state);
priv->input_state_changed = FALSE;
}
return GST_FLOW_OK;
}