QtlMovie 1.12 (A specialized FFmpeg front-end)
QtsDemux Class Referenceabstract

Abstract base class for transport stream demultiplexers. More...

Inheritance diagram for QtsDemux:
QtsPesDemux QtsSectionDemux QtsTeletextDemux QtsStandaloneTableDemux

Public Member Functions

 QtsDemux (const QtsPidSet &pidFilter=QtsAllPids)
 Constructor. More...
 
virtual ~QtsDemux ()
 Virtual destructor. More...
 
virtual void addPid (QtsPid pid)
 Add a PID to filter. More...
 
void feedPacket (const QtsTsPacket &packet)
 Feed the demux with a TS packet. More...
 
int filteredPidCount () const
 Get the number of PID's which are filtered by the demux. More...
 
qint64 lastPcr () const
 Get the last PCR found in the stream. More...
 
QtsPacketCounter packetCount () const
 Get the number of process TS packets. More...
 
virtual void removePid (QtsPid pid)
 Remove a PID to filter. More...
 
virtual void reset ()
 Reset the analysis context (partially built PES packets). More...
 
void resetPacketCount ()
 Reset the number of process TS packets. More...
 
virtual void resetPid (QtsPid pid)
 Reset the analysis context for one single PID. More...
 
virtual void setPidFilter (const QtsPidSet &pidFilter)
 Set the list of PID's to filter. More...
 

Private Member Functions

 QtsDemux () Q_DECL_EQ_DELETE
 
virtual void processTsPacket (const QtsTsPacket &packet)=0
 Feed the demux with a TS packet (PID already filtered). More...
 

Private Attributes

qint64 _lastPcr
 Last PCR is any TS packet, any PID. More...
 
QtsPacketCounter _packetCount
 Number of TS packets in demultiplexed stream. More...
 
QtsPidSet _pidFilter
 PIDs to filter. More...
 

Detailed Description

Abstract base class for transport stream demultiplexers.

Constructor & Destructor Documentation

◆ QtsDemux() [1/2]

QtsDemux::QtsDemux ( const QtsPidSet pidFilter = QtsAllPids)
explicit

Constructor.

Parameters
[in]pidFilterSet of PID's to filter.

◆ ~QtsDemux()

QtsDemux::~QtsDemux ( )
virtual

Virtual destructor.

◆ QtsDemux() [2/2]

QtsDemux::QtsDemux ( )
private

Member Function Documentation

◆ feedPacket()

void QtsDemux::feedPacket ( const QtsTsPacket packet)

Feed the demux with a TS packet.

Parameters
[in]packetTS packet from the stream to demultiplex. If the PID of the packet is not in the PID filter, it is ignored.

◆ setPidFilter()

void QtsDemux::setPidFilter ( const QtsPidSet pidFilter)
virtual

Set the list of PID's to filter.

Parameters
[in]pidFilterSet of PID's to filter.

◆ addPid()

void QtsDemux::addPid ( QtsPid  pid)
virtual

Add a PID to filter.

Parameters
[in]pidPID to filter.

◆ removePid()

void QtsDemux::removePid ( QtsPid  pid)
virtual

Remove a PID to filter.

Parameters
[in]pidPID to no longer filter.

◆ filteredPidCount()

int QtsDemux::filteredPidCount ( ) const
inline

Get the number of PID's which are filtered by the demux.

Returns
The number of PID's which are filtered by the demux.

◆ reset()

void QtsDemux::reset ( )
virtual

Reset the analysis context (partially built PES packets).

Useful when the transport stream changes. The PID filter and the handlers are not modified.

Reimplemented in QtsTeletextDemux, QtsSectionDemux, QtsStandaloneTableDemux, and QtsPesDemux.

◆ resetPid()

void QtsDemux::resetPid ( QtsPid  pid)
virtual

Reset the analysis context for one single PID.

Parameters
[in]pidPID to reset.

Reimplemented in QtsTeletextDemux, QtsSectionDemux, QtsStandaloneTableDemux, and QtsPesDemux.

◆ lastPcr()

qint64 QtsDemux::lastPcr ( ) const
inline

Get the last PCR found in the stream.

Returns
Last PCR value or negative if none was found.

◆ packetCount()

QtsPacketCounter QtsDemux::packetCount ( ) const
inline

Get the number of process TS packets.

Returns
The number of process TS packets.

◆ resetPacketCount()

void QtsDemux::resetPacketCount ( )
inline

Reset the number of process TS packets.

◆ processTsPacket()

virtual void QtsDemux::processTsPacket ( const QtsTsPacket packet)
privatepure virtual

Feed the demux with a TS packet (PID already filtered).

Must be implemented by subclasses.

Parameters
[in]packetThe TS packet to process.

Implemented in QtsSectionDemux, and QtsPesDemux.

Member Data Documentation

◆ _packetCount

QtsPacketCounter QtsDemux::_packetCount
private

Number of TS packets in demultiplexed stream.

◆ _lastPcr

qint64 QtsDemux::_lastPcr
private

Last PCR is any TS packet, any PID.

◆ _pidFilter

QtsPidSet QtsDemux::_pidFilter
private

PIDs to filter.


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