mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 17:20:36 +00:00
h264decoder: Allow frame gap even if it's not allowed by SPS
It's most likely the case where some frames were dropped for some reason (e.g., broken stream, network loss or so). However, decoder might be able to decode following frames even if some frames are visually broken. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1232>
This commit is contained in:
parent
80ede09193
commit
24367cbff0
1 changed files with 2 additions and 1 deletions
|
@ -537,8 +537,9 @@ gst_h264_decoder_handle_frame_num_gap (GstH264Decoder * self, gint frame_num)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!sps->gaps_in_frame_num_value_allowed_flag) {
|
if (!sps->gaps_in_frame_num_value_allowed_flag) {
|
||||||
|
/* This is likely the case where some frames were dropped.
|
||||||
|
* then we need to keep decoding without error out */
|
||||||
GST_WARNING_OBJECT (self, "Invalid frame num %d", frame_num);
|
GST_WARNING_OBJECT (self, "Invalid frame num %d", frame_num);
|
||||||
return FALSE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (self, "Handling frame num gap %d -> %d",
|
GST_DEBUG_OBJECT (self, "Handling frame num gap %d -> %d",
|
||||||
|
|
Loading…
Reference in a new issue