live
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Friends
RTPSource Class Referenceabstract

#include <RTPSource.hh>

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

Public Types

typedef void() afterGettingFunc(void *clientData, unsigned frameSize, unsigned numTruncatedBytes, struct timeval presentationTime, unsigned durationInMicroseconds)
 
typedef void() onCloseFunc(void *clientData)
 

Public Member Functions

Boolean curPacketMarkerBit () const
 
unsigned char rtpPayloadFormat () const
 
virtual Boolean hasBeenSynchronizedUsingRTCP ()
 
GroupsockRTPgs () const
 
virtual void setPacketReorderingThresholdTime (unsigned uSeconds)=0
 
void setCrypto (SRTPCryptographicContext *crypto)
 
u_int32_t SSRC () const
 
void registerForMultiplexedRTCPPackets (class RTCPInstance *rtcpInstance)
 
void deregisterForMultiplexedRTCPPackets ()
 
unsigned timestampFrequency () const
 
RTPReceptionStatsDBreceptionStatsDB () const
 
u_int32_t lastReceivedSSRC () const
 
BooleanenableRTCPReports ()
 
Boolean const & enableRTCPReports () const
 
void setStreamSocket (int sockNum, unsigned char streamChannelId, TLSState *tlsState)
 
void setAuxilliaryReadHandler (AuxHandlerFunc *handlerFunc, void *handlerClientData)
 
u_int16_t curPacketRTPSeqNum () const
 
void getNextFrame (unsigned char *to, unsigned maxSize, afterGettingFunc *afterGettingFunc, void *afterGettingClientData, onCloseFunc *onCloseFunc, void *onCloseClientData)
 
void handleClosure ()
 
void stopGettingFrames ()
 
virtual unsigned maxFrameSize () const
 
virtual void doGetNextFrame ()=0
 
Boolean isCurrentlyAwaitingData () const
 
virtual char const * MIMEtype () const
 
virtual Boolean isMPEG1or2VideoStreamFramer () const
 
virtual Boolean isMPEG4VideoStreamFramer () const
 
virtual Boolean isH264VideoStreamFramer () const
 
virtual Boolean isH265VideoStreamFramer () const
 
virtual Boolean isDVVideoStreamFramer () const
 
virtual Boolean isJPEGVideoSource () const
 
virtual Boolean isAMRAudioSource () const
 
virtual Boolean isMPEG2TransportStreamMultiplexor () const
 
UsageEnvironmentenvir () const
 
char const * name () 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 Boolean lookupByName (UsageEnvironment &env, char const *sourceName, RTPSource *&resultSource)
 
static Boolean lookupByName (UsageEnvironment &env, char const *sourceName, FramedSource *&resultSource)
 
static Boolean lookupByName (UsageEnvironment &env, char const *sourceName, MediaSource *&resultSource)
 
static Boolean lookupByName (UsageEnvironment &env, char const *mediumName, Medium *&resultMedium)
 
static void handleClosure (void *clientData)
 
static void afterGetting (FramedSource *source)
 
static void close (UsageEnvironment &env, char const *mediumName)
 
static void close (Medium *medium)
 

Protected Member Functions

 RTPSource (UsageEnvironment &env, Groupsock *RTPgs, unsigned char rtpPayloadFormat, u_int32_t rtpTimestampFrequency)
 
virtual ~RTPSource ()
 
virtual void doStopGettingFrames ()
 
TaskTokennextTask ()
 

Protected Attributes

RTPInterface fRTPInterface
 
u_int16_t fCurPacketRTPSeqNum
 
u_int32_t fCurPacketRTPTimestamp
 
Boolean fCurPacketMarkerBit
 
Boolean fCurPacketHasBeenSynchronizedUsingRTCP
 
u_int32_t fLastReceivedSSRC
 
class RTCPInstancefRTCPInstanceForMultiplexedRTCPPackets
 
SRTPCryptographicContextfCrypto
 
unsigned char * fTo
 
unsigned fMaxSize
 
unsigned fFrameSize
 
unsigned fNumTruncatedBytes
 
struct timeval fPresentationTime
 
unsigned fDurationInMicroseconds
 

Private Member Functions

u_int32_t curPacketRTPTimestamp () const
 
virtual Boolean isRTPSource () const
 
virtual void getAttributes () const
 
virtual Boolean isFramedSource () const
 
virtual Boolean isSource () const
 

Private Attributes

unsigned char fRTPPayloadFormat
 
unsigned fTimestampFrequency
 
u_int32_t fSSRC
 
Boolean fEnableRTCPReports
 
RTPReceptionStatsDBfReceptionStatsDB
 
afterGettingFuncfAfterGettingFunc
 
void * fAfterGettingClientData
 
onCloseFuncfOnCloseFunc
 
void * fOnCloseClientData
 
Boolean fIsCurrentlyAwaitingData
 
UsageEnvironmentfEnviron
 
char fMediumName [mediumNameMaxLen]
 
TaskToken fNextTask
 

Friends

class MediaSubsession
 

Detailed Description

Definition at line 36 of file RTPSource.hh.

Member Typedef Documentation

◆ afterGettingFunc

typedef void() FramedSource::afterGettingFunc(void *clientData, unsigned frameSize, unsigned numTruncatedBytes, struct timeval presentationTime, unsigned durationInMicroseconds)
inherited

Definition at line 36 of file FramedSource.hh.

◆ onCloseFunc

typedef void() FramedSource::onCloseFunc(void *clientData)
inherited

Definition at line 40 of file FramedSource.hh.

Constructor & Destructor Documentation

◆ RTPSource()

RTPSource::RTPSource ( UsageEnvironment env,
Groupsock RTPgs,
unsigned char  rtpPayloadFormat,
u_int32_t  rtpTimestampFrequency 
)
protected

◆ ~RTPSource()

virtual RTPSource::~RTPSource ( )
protectedvirtual

Member Function Documentation

◆ afterGetting()

static void FramedSource::afterGetting ( FramedSource source)
staticinherited

◆ close() [1/2]

static void Medium::close ( Medium medium)
staticinherited

◆ close() [2/2]

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

◆ curPacketMarkerBit()

Boolean RTPSource::curPacketMarkerBit ( ) const
inline

Definition at line 41 of file RTPSource.hh.

41 { return fCurPacketMarkerBit; }
Boolean fCurPacketMarkerBit
Definition: RTPSource.hh:102

References fCurPacketMarkerBit.

◆ curPacketRTPSeqNum()

u_int16_t RTPSource::curPacketRTPSeqNum ( ) const
inline

Definition at line 88 of file RTPSource.hh.

88 { return fCurPacketRTPSeqNum; }
u_int16_t fCurPacketRTPSeqNum
Definition: RTPSource.hh:100

References fCurPacketRTPSeqNum.

◆ curPacketRTPTimestamp()

u_int32_t RTPSource::curPacketRTPTimestamp ( ) const
inlineprivate

Definition at line 90 of file RTPSource.hh.

90 { return fCurPacketRTPTimestamp; }
u_int32_t fCurPacketRTPTimestamp
Definition: RTPSource.hh:101

References fCurPacketRTPTimestamp.

◆ deregisterForMultiplexedRTCPPackets()

void RTPSource::deregisterForMultiplexedRTCPPackets ( )
inline

Definition at line 60 of file RTPSource.hh.

#define NULL
void registerForMultiplexedRTCPPackets(class RTCPInstance *rtcpInstance)
Definition: RTPSource.hh:57

References NULL, and registerForMultiplexedRTCPPackets().

◆ doGetNextFrame()

virtual void FramedSource::doGetNextFrame ( )
pure virtualinherited

◆ doStopGettingFrames()

virtual void FramedSource::doStopGettingFrames ( )
protectedvirtualinherited

◆ enableRTCPReports() [1/2]

Boolean& RTPSource::enableRTCPReports ( )
inline

Definition at line 71 of file RTPSource.hh.

71 { return fEnableRTCPReports; }
Boolean fEnableRTCPReports
Definition: RTPSource.hh:117

References fEnableRTCPReports.

◆ enableRTCPReports() [2/2]

Boolean const& RTPSource::enableRTCPReports ( ) const
inline

Definition at line 72 of file RTPSource.hh.

72 { return fEnableRTCPReports; }

References fEnableRTCPReports.

◆ envir()

UsageEnvironment& Medium::envir ( ) const
inlineinherited

◆ getAttributes()

virtual void RTPSource::getAttributes ( ) const
privatevirtual

Reimplemented from MediaSource.

◆ getNextFrame()

void FramedSource::getNextFrame ( unsigned char *  to,
unsigned  maxSize,
afterGettingFunc afterGettingFunc,
void *  afterGettingClientData,
onCloseFunc onCloseFunc,
void *  onCloseClientData 
)
inherited

◆ handleClosure() [1/2]

void FramedSource::handleClosure ( )
inherited

◆ handleClosure() [2/2]

static void FramedSource::handleClosure ( void *  clientData)
staticinherited

◆ hasBeenSynchronizedUsingRTCP()

virtual Boolean RTPSource::hasBeenSynchronizedUsingRTCP ( )
virtual

◆ isAMRAudioSource()

virtual Boolean MediaSource::isAMRAudioSource ( ) const
virtualinherited

Reimplemented in AMRAudioSource.

◆ isCurrentlyAwaitingData()

Boolean FramedSource::isCurrentlyAwaitingData ( ) const
inlineinherited

Definition at line 61 of file FramedSource.hh.

Boolean fIsCurrentlyAwaitingData
Definition: FramedSource.hh:92

References FramedSource::fIsCurrentlyAwaitingData.

◆ isDVVideoStreamFramer()

virtual Boolean MediaSource::isDVVideoStreamFramer ( ) const
virtualinherited

Reimplemented in DVVideoStreamFramer.

◆ isFramedSource()

virtual Boolean FramedSource::isFramedSource ( ) const
privatevirtualinherited

Reimplemented from MediaSource.

◆ isH264VideoStreamFramer()

virtual Boolean MediaSource::isH264VideoStreamFramer ( ) const
virtualinherited

◆ isH265VideoStreamFramer()

virtual Boolean MediaSource::isH265VideoStreamFramer ( ) const
virtualinherited

◆ isJPEGVideoSource()

virtual Boolean MediaSource::isJPEGVideoSource ( ) const
virtualinherited

Reimplemented in JPEGVideoSource.

◆ isMediaSession()

virtual Boolean Medium::isMediaSession ( ) const
virtualinherited

Reimplemented in MediaSession.

◆ isMPEG1or2VideoStreamFramer()

virtual Boolean MediaSource::isMPEG1or2VideoStreamFramer ( ) const
virtualinherited

Reimplemented in MPEG1or2VideoStreamFramer.

◆ isMPEG2TransportStreamMultiplexor()

virtual Boolean MediaSource::isMPEG2TransportStreamMultiplexor ( ) const
virtualinherited

◆ isMPEG4VideoStreamFramer()

virtual Boolean MediaSource::isMPEG4VideoStreamFramer ( ) const
virtualinherited

Reimplemented in MPEG4VideoStreamFramer.

◆ isRTCPInstance()

virtual Boolean Medium::isRTCPInstance ( ) const
virtualinherited

Reimplemented in RTCPInstance.

◆ isRTPSource()

virtual Boolean RTPSource::isRTPSource ( ) const
privatevirtual

Reimplemented from MediaSource.

◆ 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 MediaSource::isSource ( ) const
privatevirtualinherited

Reimplemented from Medium.

◆ lastReceivedSSRC()

u_int32_t RTPSource::lastReceivedSSRC ( ) const
inline

Definition at line 68 of file RTPSource.hh.

68 { return fLastReceivedSSRC; }
u_int32_t fLastReceivedSSRC
Definition: RTPSource.hh:104

References fLastReceivedSSRC.

◆ lookupByName() [1/4]

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

◆ lookupByName() [2/4]

static Boolean FramedSource::lookupByName ( UsageEnvironment env,
char const *  sourceName,
FramedSource *&  resultSource 
)
staticinherited

◆ lookupByName() [3/4]

static Boolean MediaSource::lookupByName ( UsageEnvironment env,
char const *  sourceName,
MediaSource *&  resultSource 
)
staticinherited

◆ lookupByName() [4/4]

static Boolean RTPSource::lookupByName ( UsageEnvironment env,
char const *  sourceName,
RTPSource *&  resultSource 
)
static

◆ maxFrameSize()

virtual unsigned FramedSource::maxFrameSize ( ) const
virtualinherited

◆ MIMEtype()

virtual char const* MediaSource::MIMEtype ( ) const
virtualinherited

◆ 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.

◆ receptionStatsDB()

RTPReceptionStatsDB& RTPSource::receptionStatsDB ( ) const
inline

Definition at line 64 of file RTPSource.hh.

64  {
65  return *fReceptionStatsDB;
66  }
RTPReceptionStatsDB * fReceptionStatsDB
Definition: RTPSource.hh:119

References fReceptionStatsDB.

◆ registerForMultiplexedRTCPPackets()

void RTPSource::registerForMultiplexedRTCPPackets ( class RTCPInstance rtcpInstance)
inline

Definition at line 57 of file RTPSource.hh.

57  {
59  }
class RTCPInstance * fRTCPInstanceForMultiplexedRTCPPackets
Definition: RTPSource.hh:105

References fRTCPInstanceForMultiplexedRTCPPackets.

Referenced by deregisterForMultiplexedRTCPPackets().

◆ RTPgs()

Groupsock* RTPSource::RTPgs ( ) const
inline

Definition at line 47 of file RTPSource.hh.

47 { return fRTPInterface.gs(); }
Groupsock * gs() const
Definition: RTPInterface.hh:51
RTPInterface fRTPInterface
Definition: RTPSource.hh:99

References fRTPInterface, and RTPInterface::gs().

◆ rtpPayloadFormat()

unsigned char RTPSource::rtpPayloadFormat ( ) const
inline

Definition at line 43 of file RTPSource.hh.

43 { return fRTPPayloadFormat; }
unsigned char fRTPPayloadFormat
Definition: RTPSource.hh:114

References fRTPPayloadFormat.

◆ setAuxilliaryReadHandler()

void RTPSource::setAuxilliaryReadHandler ( AuxHandlerFunc handlerFunc,
void *  handlerClientData 
)
inline

Definition at line 79 of file RTPSource.hh.

80  {
82  handlerClientData);
83  }
void setAuxilliaryReadHandler(AuxHandlerFunc *handlerFunc, void *handlerClientData)
Definition: RTPInterface.hh:79

References fRTPInterface, and RTPInterface::setAuxilliaryReadHandler().

◆ setCrypto()

void RTPSource::setCrypto ( SRTPCryptographicContext crypto)
inline

Definition at line 51 of file RTPSource.hh.

51 { fCrypto = crypto; }
SRTPCryptographicContext * fCrypto
Definition: RTPSource.hh:106

References fCrypto.

◆ setPacketReorderingThresholdTime()

virtual void RTPSource::setPacketReorderingThresholdTime ( unsigned  uSeconds)
pure virtual

Implemented in MultiFramedRTPSource.

◆ setStreamSocket()

void RTPSource::setStreamSocket ( int  sockNum,
unsigned char  streamChannelId,
TLSState tlsState 
)
inline

Definition at line 74 of file RTPSource.hh.

74  {
75  // hack to allow sending RTP over TCP (RFC 2236, section 10.12)
76  fRTPInterface.setStreamSocket(sockNum, streamChannelId, tlsState);
77  }
void setStreamSocket(int sockNum, unsigned char streamChannelId, TLSState *tlsState)

References fRTPInterface, and RTPInterface::setStreamSocket().

◆ SSRC()

u_int32_t RTPSource::SSRC ( ) const
inline

Definition at line 54 of file RTPSource.hh.

54 { return fSSRC; }
u_int32_t fSSRC
Definition: RTPSource.hh:116

References fSSRC.

◆ stopGettingFrames()

void FramedSource::stopGettingFrames ( )
inherited

◆ timestampFrequency()

unsigned RTPSource::timestampFrequency ( ) const
inline

Definition at line 62 of file RTPSource.hh.

62 {return fTimestampFrequency;}
unsigned fTimestampFrequency
Definition: RTPSource.hh:115

References fTimestampFrequency.

Friends And Related Function Documentation

◆ MediaSubsession

friend class MediaSubsession
friend

Definition at line 89 of file RTPSource.hh.

Field Documentation

◆ fAfterGettingClientData

void* FramedSource::fAfterGettingClientData
privateinherited

Definition at line 88 of file FramedSource.hh.

◆ fAfterGettingFunc

afterGettingFunc* FramedSource::fAfterGettingFunc
privateinherited

Definition at line 87 of file FramedSource.hh.

◆ fCrypto

SRTPCryptographicContext* RTPSource::fCrypto
protected

Definition at line 106 of file RTPSource.hh.

Referenced by setCrypto().

◆ fCurPacketHasBeenSynchronizedUsingRTCP

Boolean RTPSource::fCurPacketHasBeenSynchronizedUsingRTCP
protected

Definition at line 103 of file RTPSource.hh.

◆ fCurPacketMarkerBit

Boolean RTPSource::fCurPacketMarkerBit
protected

Definition at line 102 of file RTPSource.hh.

Referenced by curPacketMarkerBit().

◆ fCurPacketRTPSeqNum

u_int16_t RTPSource::fCurPacketRTPSeqNum
protected

Definition at line 100 of file RTPSource.hh.

Referenced by curPacketRTPSeqNum().

◆ fCurPacketRTPTimestamp

u_int32_t RTPSource::fCurPacketRTPTimestamp
protected

Definition at line 101 of file RTPSource.hh.

Referenced by curPacketRTPTimestamp().

◆ fDurationInMicroseconds

unsigned FramedSource::fDurationInMicroseconds
protectedinherited

◆ fEnableRTCPReports

Boolean RTPSource::fEnableRTCPReports
private

Definition at line 117 of file RTPSource.hh.

Referenced by enableRTCPReports().

◆ fEnviron

UsageEnvironment& Medium::fEnviron
privateinherited

Definition at line 82 of file Media.hh.

Referenced by Medium::envir().

◆ fFrameSize

unsigned FramedSource::fFrameSize
protectedinherited

◆ fIsCurrentlyAwaitingData

Boolean FramedSource::fIsCurrentlyAwaitingData
privateinherited

Definition at line 92 of file FramedSource.hh.

Referenced by FramedSource::isCurrentlyAwaitingData().

◆ fLastReceivedSSRC

u_int32_t RTPSource::fLastReceivedSSRC
protected

Definition at line 104 of file RTPSource.hh.

Referenced by lastReceivedSSRC().

◆ fMaxSize

unsigned FramedSource::fMaxSize
protectedinherited

◆ fMediumName

char Medium::fMediumName[mediumNameMaxLen]
privateinherited

Definition at line 83 of file Media.hh.

Referenced by Medium::name().

◆ fNextTask

TaskToken Medium::fNextTask
privateinherited

Definition at line 84 of file Media.hh.

Referenced by Medium::nextTask().

◆ fNumTruncatedBytes

unsigned FramedSource::fNumTruncatedBytes
protectedinherited

◆ fOnCloseClientData

void* FramedSource::fOnCloseClientData
privateinherited

Definition at line 90 of file FramedSource.hh.

◆ fOnCloseFunc

onCloseFunc* FramedSource::fOnCloseFunc
privateinherited

Definition at line 89 of file FramedSource.hh.

◆ fPresentationTime

struct timeval FramedSource::fPresentationTime
protectedinherited

◆ fReceptionStatsDB

RTPReceptionStatsDB* RTPSource::fReceptionStatsDB
private

Definition at line 119 of file RTPSource.hh.

Referenced by receptionStatsDB().

◆ fRTCPInstanceForMultiplexedRTCPPackets

class RTCPInstance* RTPSource::fRTCPInstanceForMultiplexedRTCPPackets
protected

Definition at line 105 of file RTPSource.hh.

Referenced by registerForMultiplexedRTCPPackets().

◆ fRTPInterface

RTPInterface RTPSource::fRTPInterface
protected

Definition at line 99 of file RTPSource.hh.

Referenced by RTPgs(), setAuxilliaryReadHandler(), and setStreamSocket().

◆ fRTPPayloadFormat

unsigned char RTPSource::fRTPPayloadFormat
private

Definition at line 114 of file RTPSource.hh.

Referenced by rtpPayloadFormat().

◆ fSSRC

u_int32_t RTPSource::fSSRC
private

Definition at line 116 of file RTPSource.hh.

Referenced by SSRC().

◆ fTimestampFrequency

unsigned RTPSource::fTimestampFrequency
private

Definition at line 115 of file RTPSource.hh.

Referenced by timestampFrequency().

◆ fTo

unsigned char* FramedSource::fTo
protectedinherited

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