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
virtual Boolean isDarwinInjector () 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]

Friends

class MediaLookupTable

Detailed Description

Definition at line 33 of file MPEG2TransportStreamIndexFile.hh.


Constructor & Destructor Documentation

virtual MPEG2TransportStreamIndexFile::~MPEG2TransportStreamIndexFile (  )  [virtual]

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


Member Function Documentation

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

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

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

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

float MPEG2TransportStreamIndexFile::getPlayingDuration (  ) 

void MPEG2TransportStreamIndexFile::stopReading (  )  [inline]

Definition at line 60 of file MPEG2TransportStreamIndexFile.hh.

References closeFid().

00060 { closeFid(); }

int MPEG2TransportStreamIndexFile::mpegVersion (  ) 

Boolean MPEG2TransportStreamIndexFile::openFid (  )  [private]

Boolean MPEG2TransportStreamIndexFile::seekToIndexRecord ( unsigned long  indexRecordNumber  )  [private]

Boolean MPEG2TransportStreamIndexFile::readIndexRecord ( unsigned long  indexRecordNum  )  [private]

Boolean MPEG2TransportStreamIndexFile::readOneIndexRecord ( unsigned long  indexRecordNum  )  [private]

void MPEG2TransportStreamIndexFile::closeFid (  )  [private]

Referenced by stopReading().

u_int8_t MPEG2TransportStreamIndexFile::recordTypeFromBuf (  )  [inline, private]

Definition at line 75 of file MPEG2TransportStreamIndexFile.hh.

References fBuf.

00075 { return fBuf[0]; }

u_int8_t MPEG2TransportStreamIndexFile::offsetFromBuf (  )  [inline, private]

Definition at line 76 of file MPEG2TransportStreamIndexFile.hh.

References fBuf.

00076 { return fBuf[1]; }

u_int8_t MPEG2TransportStreamIndexFile::sizeFromBuf (  )  [inline, private]

Definition at line 77 of file MPEG2TransportStreamIndexFile.hh.

References fBuf.

00077 { return fBuf[2]; }

float MPEG2TransportStreamIndexFile::pcrFromBuf (  )  [private]

unsigned long MPEG2TransportStreamIndexFile::tsPacketNumFromBuf (  )  [private]

void MPEG2TransportStreamIndexFile::setMPEGVersionFromRecordType ( u_int8_t  recordType  )  [private]

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

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

static void Medium::close ( UsageEnvironment env,
char const *  mediumName 
) [static, inherited]

static void Medium::close ( Medium medium  )  [static, inherited]

UsageEnvironment& Medium::envir (  )  const [inline, inherited]

Definition at line 59 of file Media.hh.

References Medium::fEnviron.

Referenced by MediaSubsession::env(), RTSPServer::RTSPClientSession::envir(), RTSPServer::RTSPClientConnection::envir(), and RTPInterface::envir().

00059 {return fEnviron;}

char const* Medium::name (  )  const [inline, inherited]

Definition at line 61 of file Media.hh.

References Medium::fMediumName.

00061 {return fMediumName;}

virtual Boolean Medium::isSource (  )  const [virtual, inherited]

Reimplemented in MediaSource.

virtual Boolean Medium::isSink (  )  const [virtual, inherited]

Reimplemented in MediaSink.

virtual Boolean Medium::isRTCPInstance (  )  const [virtual, inherited]

Reimplemented in RTCPInstance.

virtual Boolean Medium::isRTSPClient (  )  const [virtual, inherited]

Reimplemented in RTSPClient.

virtual Boolean Medium::isRTSPServer (  )  const [virtual, inherited]

Reimplemented in RTSPServer.

virtual Boolean Medium::isMediaSession (  )  const [virtual, inherited]

Reimplemented in MediaSession.

virtual Boolean Medium::isServerMediaSession (  )  const [virtual, inherited]

Reimplemented in ServerMediaSession.

virtual Boolean Medium::isDarwinInjector (  )  const [virtual, inherited]

Reimplemented in DarwinInjector.

TaskToken& Medium::nextTask (  )  [inline, protected, inherited]

Definition at line 78 of file Media.hh.

References Medium::fNextTask.

00078                         {
00079         return fNextTask;
00080   }


Friends And Related Function Documentation

friend class MediaLookupTable [friend, inherited]

Definition at line 74 of file Media.hh.


Field Documentation

char* MPEG2TransportStreamIndexFile::fFileName [private]

Definition at line 86 of file MPEG2TransportStreamIndexFile.hh.

FILE* MPEG2TransportStreamIndexFile::fFid [private]

Definition at line 87 of file MPEG2TransportStreamIndexFile.hh.

int MPEG2TransportStreamIndexFile::fMPEGVersion [private]

Definition at line 88 of file MPEG2TransportStreamIndexFile.hh.

unsigned long MPEG2TransportStreamIndexFile::fCurrentIndexRecordNum [private]

Definition at line 89 of file MPEG2TransportStreamIndexFile.hh.

float MPEG2TransportStreamIndexFile::fCachedPCR [private]

Definition at line 90 of file MPEG2TransportStreamIndexFile.hh.

unsigned long MPEG2TransportStreamIndexFile::fCachedTSPacketNumber [private]

Definition at line 91 of file MPEG2TransportStreamIndexFile.hh.

unsigned long MPEG2TransportStreamIndexFile::fCachedIndexRecordNumber [private]

Definition at line 91 of file MPEG2TransportStreamIndexFile.hh.

unsigned long MPEG2TransportStreamIndexFile::fNumIndexRecords [private]

Definition at line 92 of file MPEG2TransportStreamIndexFile.hh.

unsigned char MPEG2TransportStreamIndexFile::fBuf[INDEX_RECORD_SIZE] [private]

Definition at line 93 of file MPEG2TransportStreamIndexFile.hh.

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


The documentation for this class was generated from the following file:
Generated on Wed Nov 12 10:51:25 2014 for live by  doxygen 1.5.2