diff options
author | Jesper Larsen <jesper.larsen@ixonos.com> | 2013-10-28 14:26:39 +0100 |
---|---|---|
committer | Jesper Larsen <jesper.larsen@ixonos.com> | 2014-02-06 14:11:53 +0100 |
commit | 4632ccd5bee5060fbca72d76df77d2abe182d47e (patch) | |
tree | 430aef265834aa558fadd682844c804133483f30 | |
parent | 8f429c6c6e0cc971566854e08f62fc11933a16ff (diff) | |
download | gstreamer-plugins-bad-4632ccd5bee5060fbca72d76df77d2abe182d47e.tar.gz |
mpegts: Add network_id to GstMpegTsNIT
The network_id is stored in the subtable extension. Make a field
in the GstMpegTsNIT for better code readability
-rw-r--r-- | gst-libs/gst/mpegts/gst-dvb-section.c | 3 | ||||
-rw-r--r-- | gst-libs/gst/mpegts/gst-dvb-section.h | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/gst-libs/gst/mpegts/gst-dvb-section.c b/gst-libs/gst/mpegts/gst-dvb-section.c index 0d9b203fa..323d18759 100644 --- a/gst-libs/gst/mpegts/gst-dvb-section.c +++ b/gst-libs/gst/mpegts/gst-dvb-section.c @@ -489,7 +489,8 @@ _parse_nit (GstMpegTsSection * section) data = section->data; end = data + section->section_length; - /* Skip already parsed data */ + /* Set network id, and skip the rest of what is already parsed */ + nit->network_id = section->subtable_extension; data += 8; nit->actual_network = section->table_id == 0x40; diff --git a/gst-libs/gst/mpegts/gst-dvb-section.h b/gst-libs/gst/mpegts/gst-dvb-section.h index 46883327b..a3d196905 100644 --- a/gst-libs/gst/mpegts/gst-dvb-section.h +++ b/gst-libs/gst/mpegts/gst-dvb-section.h @@ -145,17 +145,17 @@ struct _GstMpegTsNITStream /** * GstMpegTsNIT: * @actual_network: Whether this NIT corresponds to the actual stream + * @network_id: ID of the network that this NIT describes * @descriptors: (element-type GstMpegTsDescriptor): the global descriptors * @streams: (element-type GstMpegTsNITStream): the streams * * Network Information Table (ISO/IEC 13818-1 / EN 300 468) * - * The network_id is contained in the subtable_extension field of the - * container #GstMpegTsSection. */ struct _GstMpegTsNIT { gboolean actual_network; + guint16 network_id; GPtrArray *descriptors; |