Expand description
Types for processing tables of Program Specific Information in a transport stream.
§Concepts
- There are multiple standard types of Program Specific Information, like the Program Association Table and Program Map Table. Standards derived from mpegts may define their own table types.
- A PSI Table can split into Sections
- A Section can be split across a small number of individual transport stream Packets
- The payload of a section may use section-syntax or compact-syntax, as indicated by the
section_syntax_indicatorattribute- Section-syntax sections have additional header data, represented by the
TableSyntaxHeadertype - Compact-syntax sections lack this extra header data
- Section-syntax sections have additional header data, represented by the
§Core types
SectionPacketConsumerconverts Packets into Sections
Note that the specific types of table such as Program Association Table are defined elsewhere with only the generic functionality in this module.
Modules§
Structs§
- Buffer
Compact Syntax Parser - Implements
CompactSyntaxPayloadParserso that any sections that cross TS-packet boundaries are collected into a single byte-buffer for easier parsing. In the common case that the section fits entirely in a single TS packet, the implementation is zero-copy. - Buffer
Section Syntax Parser - Implements
SectionSyntaxPayloadParserso that any sections that cross TS-packet boundaries are collected into a single byte-buffer for easier parsing. In the common case that the section fits entirely in a single TS packet, the implementation is zero-copy. - Compact
Syntax Section Processor - An implementation of
SectionProcessorto be used for sections that implement ‘compact syntax’ (rather than ‘section syntax’). - CrcCheck
Whole Section Syntax Payload Parser - An implementation of
WholeSectionSyntaxPayloadParserwhich will delegate to another instance ofWholeSectionSyntaxPayloadParseronly if the CRC of the section data is correct. - Dedup
Section Syntax Payload Parser - A wrapper around some other implementation of
SectionSyntaxPayloadParserthat passes-through section data, unless theTableSyntaxHeaderindicates a version_number which is the same as the last data that was passed though. - Section
Common Header - Header common to all PSI sections, whether they then use ‘section syntax’ or ‘compact syntax’.
- Section
Packet Consumer - A type for locating the headers of PSI sections, which may be split across multiple TS packets,
and passing each piece to the given
SectionProcessoras it is discovered. - Section
Syntax Section Processor - An implementation of
SectionProcessorto be used for sections that implement ‘section syntax’ (rather than ‘compact syntax’). - Table
Syntax Header - Represents the fields that appear within table sections that use the common ‘section syntax’.
Enums§
- Current
Next - Represents the value of the Transport Stream
current_next_indicatorfield.
Traits§
- Compact
Syntax Payload Parser - Trait for types that will handle MPEGTS PSI table sections with ‘compact syntax’.
- Section
Processor - Trait for types which process the data within a PSI section following the 12-byte
section_lengthfield (which is one of the items available in theSectionCommonHeaderthat is passed in. - Section
Syntax Payload Parser - Trait for types that will handle MPEGTS PSI table sections with ‘section syntax’.
- Whole
Compact Syntax Payload Parser - Trait for types that parse fully reconstructed PSI table sections.
- Whole
Section Syntax Payload Parser - Trait for types that parse fully reconstructed PSI table sections (which requires the caller to have buffered section data if it spanned multiple TS packets.