A PMT table maps a program described in the ProgramAssociationTable to various PID's which describe the multimedia contents of the program. More...
#include <mpegtables.h>
Public Member Functions | |
| ProgramMapTable (const ProgramMapTable &table) | |
| ProgramMapTable (const PSIPTable &table) | |
| uint | PCRPID (void) const |
| stream that contrains program clock reference. | |
| uint | ProgramNumber (void) const |
| uint | ProgramInfoLength (void) const |
| const unsigned char * | ProgramInfo (void) const |
| uint | StreamType (uint i) const |
| uint | StreamPID (uint i) const |
| uint | StreamInfoLength (uint i) const |
| const unsigned char * | StreamInfo (uint i) const |
| uint | StreamCount (void) const |
| void | SetPCRPID (uint pid) |
| void | SetProgramNumber (uint num) |
| void | SetStreamPID (uint i, uint pid) |
| void | SetStreamType (uint i, uint type) |
| bool | IsVideo (uint i, QString sistandard) const |
| Returns true iff the stream at index i is a video stream. | |
| bool | IsAudio (uint i, QString sistandard) const |
| Returns true iff the stream at index i is an audio stream. | |
| bool | IsEncrypted (QString sistandard) const |
| Returns true iff PMT contains CA descriptor for a vid/aud stream. | |
| bool | IsProgramEncrypted (void) const |
| Returns true iff PMT's ProgramInfo contains CA descriptor. | |
| bool | IsStreamEncrypted (uint pid) const |
| Returns true iff PMT contains CA descriptor. | |
| bool | IsStillPicture (QString sistandard) const |
| Returns true iff PMT contains a still-picture video stream. | |
| QString | StreamTypeString (uint i) const |
| Returns a string representation of type at stream index i. | |
| QString | StreamDescription (uint i, QString sistandard) const |
| Returns a better (and more expensive) string representation of type at stream index i than StreamTypeString(uint). | |
| QString | GetLanguage (uint i) const |
| Returns the cannonical language if we find the iso639 descriptor. | |
| uint | FindPIDs (uint type, vector< uint > &pids, const QString &sistandard) const |
| Finds all pids matching type. | |
| uint | FindPIDs (uint type, vector< uint > &pids, vector< uint > &types, const QString &sistandard, bool normalize) const |
| Finds all pids w/types, matching type (useful for AnyVideo/AnyAudio). | |
| int | FindPID (uint pid) const |
| Locates stream index of pid. | |
| uint | FindUnusedPID (uint desired_pid=0x20) |
| void | RemoveAllStreams (void) |
| void | AppendStream (uint pid, uint type, unsigned char *si=0, uint il=0) |
| void | Parse (void) const |
| virtual QString | toString (void) const |
| virtual QString | toStringXML (uint indent_level) const |
Static Public Member Functions | |
| static ProgramMapTable * | Create (uint programNumber, uint basepid, uint pcrpid, uint version, vector< uint > pids, vector< uint > types) |
| static ProgramMapTable * | Create (uint programNumber, uint basepid, uint pcrpid, uint version, const desc_list_t &global_desc, const vector< uint > &pids, const vector< uint > &types, const vector< desc_list_t > &prog_desc) |
Private Member Functions | |
| void | SetStreamInfoLength (uint i, uint length) |
| void | SetStreamProgramInfo (uint i, unsigned char *streamInfo, uint infoLength) |
| void | SetProgramInfoLength (uint length) |
| void | SetProgramInfo (unsigned char *streamInfo, uint infoLength) |
Static Private Member Functions | |
| static ProgramMapTable * | CreateBlank (bool smallPacket=true) |
Private Attributes | |
| vector< unsigned char * > | _ptrs |
Static Private Attributes | |
| static const uint | pmt_header = 4 |
A PMT table maps a program described in the ProgramAssociationTable to various PID's which describe the multimedia contents of the program.
Definition at line 564 of file mpegtables.h.
| ProgramMapTable::ProgramMapTable | ( | const ProgramMapTable & | table | ) | [inline] |
Definition at line 568 of file mpegtables.h.
Referenced by CreateBlank().
| ProgramMapTable::ProgramMapTable | ( | const PSIPTable & | table | ) | [inline] |
Definition at line 574 of file mpegtables.h.
| ProgramMapTable * ProgramMapTable::Create | ( | uint | programNumber, | |
| uint | basepid, | |||
| uint | pcrpid, | |||
| uint | version, | |||
| vector< uint > | pids, | |||
| vector< uint > | types | |||
| ) | [static] |
Definition at line 382 of file mpegtables.cpp.
Referenced by MPEGStreamData::CreatePMTSingleProgram(), and DTVChannel::SetChannelByString().
| ProgramMapTable * ProgramMapTable::Create | ( | uint | programNumber, | |
| uint | basepid, | |||
| uint | pcrpid, | |||
| uint | version, | |||
| const desc_list_t & | global_desc, | |||
| const vector< uint > & | pids, | |||
| const vector< uint > & | types, | |||
| const vector< desc_list_t > & | prog_desc | |||
| ) | [static] |
Definition at line 402 of file mpegtables.cpp.
| uint ProgramMapTable::PCRPID | ( | void | ) | const [inline] |
stream that contrains program clock reference.
Definition at line 592 of file mpegtables.h.
Referenced by MPEGStreamData::CreatePMTSingleProgram(), and toStringXML().
| uint ProgramMapTable::ProgramNumber | ( | void | ) | const [inline] |
Definition at line 595 of file mpegtables.h.
Referenced by MPEGStreamData::CachePMT(), CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), MPEGStreamData::GetCachedPMTMap(), ChannelScanSM::GetChannelList(), DVBSignalMonitor::HandlePMT(), DTVSignalMonitor::HandlePMT(), ChannelScanSM::HandlePMT(), MPEGStreamData::ProcessPMT(), DVBCam::SendPMT(), MPEGStreamData::TestDecryption(), toString(), and toStringXML().
| uint ProgramMapTable::ProgramInfoLength | ( | void | ) | const [inline] |
Definition at line 598 of file mpegtables.h.
Referenced by AppendStream(), CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), ChannelScanSM::GetChannelList(), ScanStreamData::GetSIStandard(), IsProgramEncrypted(), Parse(), AvFormatDecoder::ScanATSCCaptionStreams(), toString(), and toStringXML().
| const unsigned char* ProgramMapTable::ProgramInfo | ( | void | ) | const [inline] |
Definition at line 601 of file mpegtables.h.
Referenced by CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), ChannelScanSM::GetChannelList(), ScanStreamData::GetSIStandard(), IsProgramEncrypted(), AvFormatDecoder::ScanATSCCaptionStreams(), toString(), and toStringXML().
Definition at line 604 of file mpegtables.h.
Referenced by CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), ChannelScanSM::GetChannelList(), ScanStreamData::GetSIStandard(), DTVRecorder::HandleSingleProgramPMT(), AvFormatDecoder::HasVideo(), IsAudio(), IsVideo(), IPTVRecorder::ProcessTSPacket(), AvFormatDecoder::ScanDSMCCStreams(), AvFormatDecoder::ScanTeletextCaptions(), StreamDescription(), toString(), and toStringXML().
Definition at line 607 of file mpegtables.h.
Referenced by CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), PrintMPEGStreamListener::HandlePMT(), DTVRecorder::HandleSingleProgramPMT(), MPEGStreamData::TestDecryption(), toString(), and toStringXML().
Definition at line 610 of file mpegtables.h.
Referenced by AppendStream(), CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), GetLanguage(), IsAudio(), IsStillPicture(), IsStreamEncrypted(), IsVideo(), Parse(), AvFormatDecoder::ScanATSCCaptionStreams(), AvFormatDecoder::ScanDSMCCStreams(), AvFormatDecoder::ScanTeletextCaptions(), StreamDescription(), toString(), and toStringXML().
| const unsigned char* ProgramMapTable::StreamInfo | ( | uint | i | ) | const [inline] |
Definition at line 613 of file mpegtables.h.
Referenced by CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), GetLanguage(), IsAudio(), IsStillPicture(), IsStreamEncrypted(), IsVideo(), AvFormatDecoder::ScanATSCCaptionStreams(), AvFormatDecoder::ScanDSMCCStreams(), AvFormatDecoder::ScanTeletextCaptions(), StreamDescription(), toString(), and toStringXML().
| uint ProgramMapTable::StreamCount | ( | void | ) | const [inline] |
Definition at line 616 of file mpegtables.h.
Referenced by AppendStream(), CreateCAPMT(), MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), ChannelScanSM::GetChannelList(), PrintMPEGStreamListener::HandlePMT(), DTVSignalMonitor::HandlePMT(), DTVRecorder::HandlePMT(), DTVRecorder::HandleSingleProgramPMT(), AvFormatDecoder::HasVideo(), IsEncrypted(), IsStillPicture(), AvFormatDecoder::ScanATSCCaptionStreams(), AvFormatDecoder::ScanDSMCCStreams(), AvFormatDecoder::ScanTeletextCaptions(), MPEGStreamData::TestDecryption(), toString(), and toStringXML().
| void ProgramMapTable::SetPCRPID | ( | uint | pid | ) | [inline] |
Definition at line 620 of file mpegtables.h.
| void ProgramMapTable::SetProgramNumber | ( | uint | num | ) | [inline] |
Definition at line 626 of file mpegtables.h.
Definition at line 628 of file mpegtables.h.
Referenced by AppendStream().
Definition at line 634 of file mpegtables.h.
Referenced by AppendStream().
Returns true iff the stream at index i is a video stream.
This of course returns true if StreamID::IsVideo() is true. And, it also returns true if IsVideo returns true after StreamID::Normalize() is used on the stream type.
| i | index of stream |
Definition at line 489 of file mpegtables.cpp.
Referenced by FindPIDs(), PrintMPEGStreamListener::HandlePMT(), DTVSignalMonitor::HandlePMT(), DTVRecorder::HandlePMT(), AvFormatDecoder::HasVideo(), IsEncrypted(), IsStillPicture(), AvFormatDecoder::ScanATSCCaptionStreams(), and MPEGStreamData::TestDecryption().
Returns true iff the stream at index i is an audio stream.
This of course returns true if StreamID::IsAudio() is true. And, it also returns true if IsAudio returns true after StreamID::Normalize() is used on the stream type.
| i | index of stream |
Definition at line 510 of file mpegtables.cpp.
Referenced by FindPIDs(), PrintMPEGStreamListener::HandlePMT(), DTVSignalMonitor::HandlePMT(), DTVRecorder::HandlePMT(), IsEncrypted(), and MPEGStreamData::TestDecryption().
| bool ProgramMapTable::IsEncrypted | ( | QString | sistandard | ) | const |
Returns true iff PMT contains CA descriptor for a vid/aud stream.
Definition at line 525 of file mpegtables.cpp.
Referenced by ChannelScanSM::GetChannelList(), DTVSignalMonitor::HandlePMT(), and ChannelScanSM::HandlePMT().
| bool ProgramMapTable::IsProgramEncrypted | ( | void | ) | const |
Returns true iff PMT's ProgramInfo contains CA descriptor.
Definition at line 541 of file mpegtables.cpp.
Referenced by IsEncrypted(), and MPEGStreamData::TestDecryption().
Returns true iff PMT contains CA descriptor.
| i | index of stream |
Definition at line 567 of file mpegtables.cpp.
Referenced by IsEncrypted(), and MPEGStreamData::TestDecryption().
| bool ProgramMapTable::IsStillPicture | ( | QString | sistandard | ) | const |
Returns true iff PMT contains a still-picture video stream.
Definition at line 588 of file mpegtables.cpp.
| QString ProgramMapTable::StreamTypeString | ( | uint | i | ) | const [inline] |
Returns a string representation of type at stream index i.
Definition at line 646 of file mpegtables.h.
Referenced by toString(), and toStringXML().
| QString ProgramMapTable::StreamDescription | ( | uint | i, | |
| QString | sistandard | |||
| ) | const |
Returns a better (and more expensive) string representation of type at stream index i than StreamTypeString(uint).
Definition at line 1087 of file mpegtables.cpp.
Referenced by CreateCAPMT().
| QString ProgramMapTable::GetLanguage | ( | uint | i | ) | const |
Returns the cannonical language if we find the iso639 descriptor.
Definition at line 1073 of file mpegtables.cpp.
Referenced by StreamDescription().
| uint ProgramMapTable::FindPIDs | ( | uint | type, | |
| vector< uint > & | pids, | |||
| const QString & | sistandard | |||
| ) | const |
Finds all pids matching type.
| type | StreamType to match | |
| pids | vector pids will be added to | |
| sistandard | standard to use in determining if this is a A/V stream |
Definition at line 612 of file mpegtables.cpp.
| uint ProgramMapTable::FindPIDs | ( | uint | type, | |
| vector< uint > & | pids, | |||
| vector< uint > & | types, | |||
| const QString & | sistandard, | |||
| bool | normalize | |||
| ) | const |
Finds all pids w/types, matching type (useful for AnyVideo/AnyAudio).
| type | StreamType to match | |
| pids | vector pids will be added to | |
| types | vector types will be added to | |
| sistandard | standard to use in determining if this is a A/V stream | |
| normalize | if set types will be normalized |
Definition at line 648 of file mpegtables.cpp.
| int ProgramMapTable::FindPID | ( | uint | pid | ) | const [inline] |
Locates stream index of pid.
Definition at line 661 of file mpegtables.h.
Referenced by MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), FindUnusedPID(), and IPTVRecorder::ProcessTSPacket().
Definition at line 701 of file mpegtables.cpp.
| void ProgramMapTable::RemoveAllStreams | ( | void | ) | [inline] |
Definition at line 670 of file mpegtables.h.
Definition at line 466 of file mpegtables.cpp.
| void ProgramMapTable::Parse | ( | void | ) | const |
Definition at line 445 of file mpegtables.cpp.
Referenced by MPEGStreamData::CreatePMTSingleProgram(), FindPIDs(), GetLanguage(), IsAudio(), IsVideo(), StreamDescription(), toString(), and toStringXML().
| QString ProgramMapTable::toString | ( | void | ) | const [virtual] |
Reimplemented from PSIPTable.
Definition at line 840 of file mpegtables.cpp.
Referenced by MPEGStreamData::CreatePMTSingleProgram(), ChannelScanSM::HandlePMT(), Parse(), and StreamDescription().
| QString ProgramMapTable::toStringXML | ( | uint | indent_level | ) | const [virtual] |
Reimplemented from PSIPTable.
Definition at line 875 of file mpegtables.cpp.
Definition at line 683 of file mpegtables.h.
| void ProgramMapTable::SetStreamProgramInfo | ( | uint | i, | |
| unsigned char * | streamInfo, | |||
| uint | infoLength | |||
| ) | [inline, private] |
Definition at line 689 of file mpegtables.h.
Referenced by AppendStream().
| void ProgramMapTable::SetProgramInfoLength | ( | uint | length | ) | [inline, private] |
Definition at line 696 of file mpegtables.h.
| void ProgramMapTable::SetProgramInfo | ( | unsigned char * | streamInfo, | |
| uint | infoLength | |||
| ) | [inline, private] |
Definition at line 702 of file mpegtables.h.
| ProgramMapTable * ProgramMapTable::CreateBlank | ( | bool | smallPacket = true |
) | [static, private] |
Definition at line 357 of file mpegtables.cpp.
Referenced by Create().
const uint ProgramMapTable::pmt_header = 4 [static, private] |
Definition at line 710 of file mpegtables.h.
Referenced by AppendStream(), and Parse().
vector<unsigned char*> ProgramMapTable::_ptrs [mutable, private] |
Definition at line 711 of file mpegtables.h.
Referenced by AppendStream(), and Parse().
1.6.3