TSDuck v3.38-3704
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches
ts::PMT::Stream Class Reference

Description of an elementary stream. More...

#include <tsPMT.h>

Inheritance diagram for ts::PMT::Stream:
Collaboration diagram for ts::PMT::Stream:

Public Member Functions

 Stream (const AbstractTable *table, uint8_t type=0)
 Constructor.
 
PIDClass getClass (const DuckContext &duck) const
 Get the PID class of the stream.
 
CodecType getCodec (const DuckContext &duck) const
 Try to determine the codec which is used in the stream.
 
bool getComponentTag (uint8_t &tag) const
 Look for a component tag in a stream_identifier_descriptor.
 
bool isAudio (const DuckContext &duck) const
 Check if an elementary stream carries audio.
 
bool isSubtitles (const DuckContext &duck) const
 Check if an elementary stream carries subtitles.
 
bool isVideo (const DuckContext &duck) const
 Check if an elementary stream carries video.
 

Public Attributes

DescriptorList descs
 List of descriptors for this entry, publicly accessible.
 
size_t order_hint
 Preferred insertion index when serializing the table or NPOS if unspecified.
 
uint8_t stream_type = 0
 Stream type, one of ST_* (eg ts::ST_MPEG2_VIDEO).
 

Detailed Description

Description of an elementary stream.

Note: by inheriting from EntryWithDescriptors, there is a public field "DescriptorList descs".

Constructor & Destructor Documentation

◆ Stream()

ts::PMT::Stream::Stream ( const AbstractTable table,
uint8_t  type = 0 
)
explicit

Constructor.

Parameters
[in]tableParent PMT.
[in]typeStream type.

Member Function Documentation

◆ isAudio()

bool ts::PMT::Stream::isAudio ( const DuckContext duck) const

Check if an elementary stream carries audio.

Does not just look at the stream type. Also analyzes the descriptor list for additional information.

Parameters
[in]duckTSDuck execution context.
Returns
True if the elementary stream carries audio.

◆ isVideo()

bool ts::PMT::Stream::isVideo ( const DuckContext duck) const

Check if an elementary stream carries video.

Does not just look at the stream type. Also analyzes the descriptor list for additional information.

Parameters
[in]duckTSDuck execution context.
Returns
True if the elementary stream carries video.

◆ isSubtitles()

bool ts::PMT::Stream::isSubtitles ( const DuckContext duck) const

Check if an elementary stream carries subtitles.

Does not just look at the stream type. Also analyzes the descriptor list for additional information.

Parameters
[in]duckTSDuck execution context.
Returns
True if the elementary stream carries subtitles.

◆ getClass()

PIDClass ts::PMT::Stream::getClass ( const DuckContext duck) const

Get the PID class of the stream.

Look at the stream type and the descriptor list.

Parameters
[in]duckTSDuck execution context.
Returns
The PID class (PIDClass::DATA if unknown component type).

◆ getCodec()

CodecType ts::PMT::Stream::getCodec ( const DuckContext duck) const

Try to determine the codec which is used in the stream.

Look at the stream type and the descriptor list.

Parameters
[in]duckTSDuck execution context.
Returns
The codec type (CodecType::UNDEFINED if unknown).

◆ getComponentTag()

bool ts::PMT::Stream::getComponentTag ( uint8_t &  tag) const

Look for a component tag in a stream_identifier_descriptor.

Parameters
[out]tagFirst component tag found, unmodified if none found.
Returns
True if a component tag was found.

Member Data Documentation

◆ order_hint

size_t ts::AbstractTable::EntryBase::order_hint
inherited

Preferred insertion index when serializing the table or NPOS if unspecified.

This is an informational hint which can be used or ignored.


The documentation for this class was generated from the following file: