mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-22 08:17:01 +00:00
adaptivedemux: Fix handling closed caption streams
Fix a typo "CLOSED_CAPTION" -> "CLOSED-CAPTION" and a broken if statement that always bailed out for closed captions Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6985>
This commit is contained in:
parent
2bd682d326
commit
73480e60d0
2 changed files with 5 additions and 4 deletions
|
@ -1317,7 +1317,7 @@ gst_m3u8_get_hls_media_type_from_string (const gchar * type_name)
|
|||
return GST_HLS_MEDIA_TYPE_VIDEO;
|
||||
if (strcmp (type_name, "SUBTITLES") == 0)
|
||||
return GST_HLS_MEDIA_TYPE_SUBTITLES;
|
||||
if (strcmp (type_name, "CLOSED_CAPTIONS") == 0)
|
||||
if (strcmp (type_name, "CLOSED-CAPTIONS") == 0)
|
||||
return GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS;
|
||||
|
||||
return GST_HLS_MEDIA_TYPE_INVALID;
|
||||
|
@ -1406,7 +1406,7 @@ gst_m3u8_parse_media (gchar * desc, const gchar * base_uri)
|
|||
if (media->group_id == NULL || media->name == NULL)
|
||||
goto required_attributes_missing;
|
||||
|
||||
if (media->mtype == GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS)
|
||||
if (media->mtype == GST_HLS_MEDIA_TYPE_CLOSED_CAPTIONS && media->uri != NULL)
|
||||
goto uri_with_cc;
|
||||
|
||||
GST_DEBUG ("media: %s, group '%s', name '%s', uri '%s', %s %s %s, lang=%s",
|
||||
|
|
|
@ -2650,7 +2650,7 @@ gst_m3u8_get_hls_media_type_from_string (const gchar * type_name)
|
|||
return GST_HLS_RENDITION_STREAM_TYPE_VIDEO;
|
||||
if (strcmp (type_name, "SUBTITLES") == 0)
|
||||
return GST_HLS_RENDITION_STREAM_TYPE_SUBTITLES;
|
||||
if (strcmp (type_name, "CLOSED_CAPTIONS") == 0)
|
||||
if (strcmp (type_name, "CLOSED-CAPTIONS") == 0)
|
||||
return GST_HLS_RENDITION_STREAM_TYPE_CLOSED_CAPTIONS;
|
||||
|
||||
return GST_HLS_RENDITION_STREAM_TYPE_INVALID;
|
||||
|
@ -2736,7 +2736,8 @@ gst_m3u8_parse_media (gchar * desc, const gchar * base_uri)
|
|||
if (media->group_id == NULL || media->name == NULL)
|
||||
goto required_attributes_missing;
|
||||
|
||||
if (media->mtype == GST_HLS_RENDITION_STREAM_TYPE_CLOSED_CAPTIONS)
|
||||
if (media->mtype == GST_HLS_RENDITION_STREAM_TYPE_CLOSED_CAPTIONS
|
||||
&& media->uri != NULL)
|
||||
goto uri_with_cc;
|
||||
|
||||
GST_DEBUG ("media: %s, group '%s', name '%s', uri '%s', %s %s %s, lang=%s",
|
||||
|
|
Loading…
Reference in a new issue