tsdemux: extract ISO 639 language codes for subtitles into taglists

https://bugzilla.gnome.org/show_bug.cgi?id=680200
This commit is contained in:
Matthias Hardt 2012-07-26 20:38:28 +02:00 committed by Tim-Philipp Müller
parent e454e9a862
commit 0e3fdb1e16
2 changed files with 9 additions and 0 deletions

View file

@ -1002,6 +1002,9 @@ mpegts_packetizer_parse_pmt (MpegTSPacketizer2 * packetizer,
/* ISO 639 LANGUAGE */
desc_data = gst_mpeg_descriptor_find (&desc, DESC_ISO_639_LANGUAGE);
if (!desc_data) {
desc_data = gst_mpeg_descriptor_find (&desc, DESC_DVB_SUBTITLING);
}
if (desc_data && DESC_ISO_639_LANGUAGE_codes_n (desc_data)) {
gchar *lang_code;
gchar *language_n = (gchar *)

View file

@ -637,6 +637,12 @@ gst_ts_demux_create_tags (TSDemuxStream * stream)
desc = mpegts_get_descriptor_from_stream ((MpegTSBaseStream *) stream,
DESC_ISO_639_LANGUAGE);
if (!desc) {
desc = mpegts_get_descriptor_from_stream ((MpegTSBaseStream *) stream,
DESC_DVB_SUBTITLING);
}
if (desc) {
if (!stream->taglist)
stream->taglist = gst_tag_list_new_empty ();