DVB Tables
Russel Winder
russel at winder.org.uk
Fri May 26 06:31:26 UTC 2017
On Fri, 2017-05-26 at 08:01 +0200, Edward Hervey wrote:
>
[…]
> I did my best to make it a 1:1 mapping with the field naming in the
> specs. Which part don't you think is similar ?
>
It may well be then that I am just misunderstanding – actually I hope
so, as it will easier to fix that. :-)
The standard presents an EIT section as follows (Table 7 of the
standard):
event_information_section(){
table_id
section_syntax_indicator
reserved_future_use
reserved
section_length
service_id
reserved
version_number
current_next_indicator
section_number
last_section_number
transport_stream_id
original_network_id
segment_last_section_number
last_table_id
for(i=0;i<N;i++){
event_id
start_time
duration
running_status
free_CA_mode
descriptors_loop_length
for(i=0;i<N;i++){
descriptor()
}
}
CRC_32
}
The GstMpegtsEIT structure is though:
struct GstMpegtsEIT {
guint16 transport_stream_id;
guint16 original_network_id;
guint8 segment_last_section_number;
guint8 last_table_id;
gboolean actual_stream;
gboolean present_following;
GPtrArray *events;
};
which doesn't seem to map to any bits of the standard's Table 7 –
though it is clear that the events, a sequence of GstMpegtsEITEvent
structures does somewhat map to the N events in the section:
struct GstMpegtsEITEvent {
guint16 event_id;
GstDateTime *start_time;
guint32 duration;
GstMpegtsRunningStatus running_status;
gboolean free_CA_mode;
GPtrArray *descriptors;
};
My code is getting the events, seemingly correctly (*), but it is the
SID and stuff like that that give the channel numbers that I cannot see
how to extract. The EIT section should have the service_id, but the
GstMpegtsEIT structure does not appear to offer it.
I guess I had expected the GStreamer structures to map more or less
exactly to the tables in the standard, but this seems to be only
partially true. Where it is true, it is easier to work things out.
Where it apparently is not the case, I am at a bit of a loss as to how
to proceed processing the events on the bus so as to collate the data
into an in-memory representation of the EIT.
(*) Though I regularly get memory errors due to all the malloc and free
stuff that I really do not properly understand yet. Oh for doing this
in D with it's garbage collector.
--
Russel.
=============================================================================
Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder at ekiga.net
41 Buckmaster Road m: +44 7770 465 077 xmpp: russel at winder.org.uk
London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20170526/a672f8b6/attachment.sig>
More information about the gstreamer-devel
mailing list