diff options
author | Stefan Ringel <linuxtv@stefanringel.de> | 2014-05-26 20:38:45 +0200 |
---|---|---|
committer | Edward Hervey <bilboed@bilboed.com> | 2014-05-27 15:34:41 +0200 |
commit | c0ac6ce43266c58c4daa329b192500fa2d6a19e1 (patch) | |
tree | 6a9d2e4328e0e1f22cba386e546c31236d151deb /tests | |
parent | 2277011875d776ca92f6d00e3fdde900e16fd8fc (diff) | |
download | gstreamer-plugins-bad-c0ac6ce43266c58c4daa329b192500fa2d6a19e1.tar.gz |
examples: Add support for DVB multilingual component descriptor
https://bugzilla.gnome.org/show_bug.cgi?id=728429
Diffstat (limited to 'tests')
-rw-r--r-- | tests/examples/mpegts/ts-parser.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/examples/mpegts/ts-parser.c b/tests/examples/mpegts/ts-parser.c index 96f469677..67cc903ee 100644 --- a/tests/examples/mpegts/ts-parser.c +++ b/tests/examples/mpegts/ts-parser.c @@ -244,6 +244,27 @@ dump_multiligual_service_name (GstMpegTsDescriptor * desc, guint spacing) } static void +dump_multiligual_component (GstMpegTsDescriptor * desc, guint spacing) +{ + GPtrArray *items; + guint8 tag; + if (gst_mpegts_descriptor_parse_dvb_multilingual_component (desc, &tag, + &items)) { + guint8 i; + g_printf ("%*s component_tag : 0x%02x\n", spacing, "", tag); + for (i = 0; i < items->len; i++) { + GstMpegTsDvbMultilingualComponentItem *item = + g_ptr_array_index (items, i); + g_printf ("%*s item : %u\n", spacing, "", i); + g_printf ("%*s language_code : %s\n", spacing, "", + item->language_code); + g_printf ("%*s description : %s\n", spacing, "", item->description); + } + g_ptr_array_unref (items); + } +} + +static void dump_iso_639_language (GstMpegTsDescriptor * desc, guint spacing) { guint i; @@ -345,6 +366,11 @@ dump_descriptors (GPtrArray * descriptors, guint spacing) dump_multiligual_service_name (desc, spacing + 2); break; } + case GST_MTS_DESC_DVB_MULTILINGUAL_COMPONENT: + { + dump_multiligual_component (desc, spacing + 2); + break; + } case GST_MTS_DESC_ISO_639_LANGUAGE: dump_iso_639_language (desc, spacing + 2); break; |