mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-18 21:35:44 +00:00
h264parser: Return BROKEN_LINK for missing SPS
When parsing SEI that require an SPS, return GST_H264_PARSER_BROKEN_LINK instead of a generic parsing error to let callers distinguish bitstream errors from (expected) missing packets when resuming decode.
This commit is contained in:
parent
34b0eb4953
commit
a978bd2cab
1 changed files with 5 additions and 2 deletions
|
@ -964,10 +964,13 @@ static GstH264ParserResult
|
|||
gst_h264_parser_parse_pic_timing (GstH264NalParser * nalparser,
|
||||
GstH264PicTiming * tim, NalReader * nr)
|
||||
{
|
||||
GstH264ParserResult error = GST_H264_PARSER_ERROR;
|
||||
|
||||
GST_DEBUG ("parsing \"Picture timing\"");
|
||||
if (!nalparser->last_sps || !nalparser->last_sps->valid) {
|
||||
GST_WARNING ("didn't get the associated sequence paramater set for the "
|
||||
GST_WARNING ("didn't get the associated sequence parameter set for the "
|
||||
"current access unit");
|
||||
error = GST_H264_PARSER_BROKEN_LINK;
|
||||
goto error;
|
||||
}
|
||||
|
||||
|
@ -1013,7 +1016,7 @@ gst_h264_parser_parse_pic_timing (GstH264NalParser * nalparser,
|
|||
|
||||
error:
|
||||
GST_WARNING ("error parsing \"Picture timing\"");
|
||||
return GST_H264_PARSER_ERROR;
|
||||
return error;
|
||||
}
|
||||
|
||||
static GstH264ParserResult
|
||||
|
|
Loading…
Reference in a new issue