live
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
MPEG2TransportStreamIndexFile Class Reference

#include <MPEG2TransportStreamIndexFile.hh>

Inheritance diagram for MPEG2TransportStreamIndexFile:
Inheritance graph
[legend]
Collaboration diagram for MPEG2TransportStreamIndexFile:
Collaboration graph
[legend]

Public Member Functions

virtual ~MPEG2TransportStreamIndexFile ()
 
void lookupTSPacketNumFromNPT (float &npt, unsigned long &tsPacketNumber, unsigned long &indexRecordNumber)
 
void lookupPCRFromTSPacketNum (unsigned long &tsPacketNumber, Boolean reverseToPreviousCleanPoint, float &pcr, unsigned long &indexRecordNumber)
 
Boolean readIndexRecordValues (unsigned long indexRecordNum, unsigned long &transportPacketNum, u_int8_t &offset, u_int8_t &size, float &pcr, u_int8_t &recordType)
 
float getPlayingDuration ()
 
void stopReading ()
 
int mpegVersion ()
 
UsageEnvironmentenvir () const
 
char const * name () const
 
virtual Boolean isSource () const
 
virtual Boolean isSink () const
 
virtual Boolean isRTCPInstance () const
 
virtual Boolean isRTSPClient () const
 
virtual Boolean isRTSPServer () const
 
virtual Boolean isMediaSession () const
 
virtual Boolean isServerMediaSession () const
 

Static Public Member Functions

static MPEG2TransportStreamIndexFilecreateNew (UsageEnvironment &env, char const *indexFileName)
 
static Boolean lookupByName (UsageEnvironment &env, char const *mediumName, Medium *&resultMedium)
 
static void close (UsageEnvironment &env, char const *mediumName)
 
static void close (Medium *medium)
 

Protected Member Functions

TaskTokennextTask ()
 

Private Member Functions

 MPEG2TransportStreamIndexFile (UsageEnvironment &env, char const *indexFileName)
 
Boolean openFid ()
 
Boolean seekToIndexRecord (unsigned long indexRecordNumber)
 
Boolean readIndexRecord (unsigned long indexRecordNum)
 
Boolean readOneIndexRecord (unsigned long indexRecordNum)
 
void closeFid ()
 
u_int8_t recordTypeFromBuf ()
 
u_int8_t offsetFromBuf ()
 
u_int8_t sizeFromBuf ()
 
float pcrFromBuf ()
 
unsigned long tsPacketNumFromBuf ()
 
void setMPEGVersionFromRecordType (u_int8_t recordType)
 
Boolean rewindToCleanPoint (unsigned long &ixFound)
 

Private Attributes

char * fFileName
 
FILE * fFid
 
int fMPEGVersion
 
unsigned long fCurrentIndexRecordNum
 
float fCachedPCR
 
unsigned long fCachedTSPacketNumber
 
unsigned long fCachedIndexRecordNumber
 
unsigned long fNumIndexRecords
 
unsigned char fBuf [INDEX_RECORD_SIZE]
 

Detailed Description

Definition at line 33 of file MPEG2TransportStreamIndexFile.hh.

Constructor & Destructor Documentation

◆ ~MPEG2TransportStreamIndexFile()

virtual MPEG2TransportStreamIndexFile::~MPEG2TransportStreamIndexFile ( )
virtual

◆ MPEG2TransportStreamIndexFile()

MPEG2TransportStreamIndexFile::MPEG2TransportStreamIndexFile ( UsageEnvironment env,
char const *  indexFileName 
)
private

Member Function Documentation

◆ close() [1/2]

static void Medium::close ( UsageEnvironment env,
char const *  mediumName 
)
staticinherited

◆ close() [2/2]

static void Medium::close ( Medium medium)
staticinherited

◆ closeFid()

void MPEG2TransportStreamIndexFile::closeFid ( )
private

Referenced by stopReading().

◆ createNew()

static MPEG2TransportStreamIndexFile* MPEG2TransportStreamIndexFile::createNew ( UsageEnvironment env,
char const *  indexFileName 
)
static

◆ envir()

UsageEnvironment& Medium::envir ( ) const
inlineinherited

◆ getPlayingDuration()

float MPEG2TransportStreamIndexFile::getPlayingDuration ( )

◆ isMediaSession()

virtual Boolean Medium::isMediaSession ( ) const
virtualinherited

Reimplemented in MediaSession.

◆ isRTCPInstance()

virtual Boolean Medium::isRTCPInstance ( ) const
virtualinherited

Reimplemented in RTCPInstance.

◆ isRTSPClient()

virtual Boolean Medium::isRTSPClient ( ) const
virtualinherited

Reimplemented in RTSPClient.

◆ isRTSPServer()

virtual Boolean Medium::isRTSPServer ( ) const
virtualinherited

Reimplemented in RTSPServer.

◆ isServerMediaSession()

virtual Boolean Medium::isServerMediaSession ( ) const
virtualinherited

Reimplemented in ServerMediaSession.

◆ isSink()

virtual Boolean Medium::isSink ( ) const
virtualinherited

Reimplemented in MediaSink.

◆ isSource()

virtual Boolean Medium::isSource ( ) const
virtualinherited

Reimplemented in MediaSource.

◆ lookupByName()

static Boolean Medium::lookupByName ( UsageEnvironment env,
char const *  mediumName,
Medium *&  resultMedium 
)
staticinherited

◆ lookupPCRFromTSPacketNum()

void MPEG2TransportStreamIndexFile::lookupPCRFromTSPacketNum ( unsigned long &  tsPacketNumber,
Boolean  reverseToPreviousCleanPoint,
float &  pcr,
unsigned long &  indexRecordNumber 
)

◆ lookupTSPacketNumFromNPT()

void MPEG2TransportStreamIndexFile::lookupTSPacketNumFromNPT ( float &  npt,
unsigned long &  tsPacketNumber,
unsigned long &  indexRecordNumber 
)

◆ mpegVersion()

int MPEG2TransportStreamIndexFile::mpegVersion ( )

◆ name()

char const* Medium::name ( ) const
inlineinherited

Definition at line 61 of file Media.hh.

61 {return fMediumName;}
char fMediumName[mediumNameMaxLen]
Definition: Media.hh:83

References Medium::fMediumName.

◆ nextTask()

TaskToken& Medium::nextTask ( )
inlineprotectedinherited

Definition at line 77 of file Media.hh.

77  {
78  return fNextTask;
79  }
TaskToken fNextTask
Definition: Media.hh:84

References Medium::fNextTask.

◆ offsetFromBuf()

u_int8_t MPEG2TransportStreamIndexFile::offsetFromBuf ( )
inlineprivate

Definition at line 76 of file MPEG2TransportStreamIndexFile.hh.

76 { return fBuf[1]; }
unsigned char fBuf[INDEX_RECORD_SIZE]

References fBuf.

◆ openFid()

Boolean MPEG2TransportStreamIndexFile::openFid ( )
private

◆ pcrFromBuf()

float MPEG2TransportStreamIndexFile::pcrFromBuf ( )
private

◆ readIndexRecord()

Boolean MPEG2TransportStreamIndexFile::readIndexRecord ( unsigned long  indexRecordNum)
private

◆ readIndexRecordValues()

Boolean MPEG2TransportStreamIndexFile::readIndexRecordValues ( unsigned long  indexRecordNum,
unsigned long &  transportPacketNum,
u_int8_t &  offset,
u_int8_t &  size,
float &  pcr,
u_int8_t &  recordType 
)

◆ readOneIndexRecord()

Boolean MPEG2TransportStreamIndexFile::readOneIndexRecord ( unsigned long  indexRecordNum)
private

◆ recordTypeFromBuf()

u_int8_t MPEG2TransportStreamIndexFile::recordTypeFromBuf ( )
inlineprivate

Definition at line 75 of file MPEG2TransportStreamIndexFile.hh.

75 { return fBuf[0]; }
unsigned char fBuf[INDEX_RECORD_SIZE]

References fBuf.

◆ rewindToCleanPoint()

Boolean MPEG2TransportStreamIndexFile::rewindToCleanPoint ( unsigned long &  ixFound)
private

◆ seekToIndexRecord()

Boolean MPEG2TransportStreamIndexFile::seekToIndexRecord ( unsigned long  indexRecordNumber)
private

◆ setMPEGVersionFromRecordType()

void MPEG2TransportStreamIndexFile::setMPEGVersionFromRecordType ( u_int8_t  recordType)
private

◆ sizeFromBuf()

u_int8_t MPEG2TransportStreamIndexFile::sizeFromBuf ( )
inlineprivate

Definition at line 77 of file MPEG2TransportStreamIndexFile.hh.

77 { return fBuf[2]; }
unsigned char fBuf[INDEX_RECORD_SIZE]

References fBuf.

◆ stopReading()

void MPEG2TransportStreamIndexFile::stopReading ( )
inline

Definition at line 60 of file MPEG2TransportStreamIndexFile.hh.

References closeFid().

◆ tsPacketNumFromBuf()

unsigned long MPEG2TransportStreamIndexFile::tsPacketNumFromBuf ( )
private

Field Documentation

◆ fBuf

unsigned char MPEG2TransportStreamIndexFile::fBuf[INDEX_RECORD_SIZE]
private

Definition at line 93 of file MPEG2TransportStreamIndexFile.hh.

Referenced by offsetFromBuf(), recordTypeFromBuf(), and sizeFromBuf().

◆ fCachedIndexRecordNumber

unsigned long MPEG2TransportStreamIndexFile::fCachedIndexRecordNumber
private

Definition at line 91 of file MPEG2TransportStreamIndexFile.hh.

◆ fCachedPCR

float MPEG2TransportStreamIndexFile::fCachedPCR
private

Definition at line 90 of file MPEG2TransportStreamIndexFile.hh.

◆ fCachedTSPacketNumber

unsigned long MPEG2TransportStreamIndexFile::fCachedTSPacketNumber
private

Definition at line 91 of file MPEG2TransportStreamIndexFile.hh.

◆ fCurrentIndexRecordNum

unsigned long MPEG2TransportStreamIndexFile::fCurrentIndexRecordNum
private

Definition at line 89 of file MPEG2TransportStreamIndexFile.hh.

◆ fFid

FILE* MPEG2TransportStreamIndexFile::fFid
private

Definition at line 87 of file MPEG2TransportStreamIndexFile.hh.

◆ fFileName

char* MPEG2TransportStreamIndexFile::fFileName
private

Definition at line 86 of file MPEG2TransportStreamIndexFile.hh.

◆ fMPEGVersion

int MPEG2TransportStreamIndexFile::fMPEGVersion
private

Definition at line 88 of file MPEG2TransportStreamIndexFile.hh.

◆ fNumIndexRecords

unsigned long MPEG2TransportStreamIndexFile::fNumIndexRecords
private

Definition at line 92 of file MPEG2TransportStreamIndexFile.hh.


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