#include <RTPInnerPacket.h>
Public Types | |
enum | RTP_INP_TYPE { RTP_INP_UNDEF, RTP_INP_INITIALIZE_PROFILE, RTP_INP_PROFILE_INITIALIZED, RTP_INP_INITIALIZE_RTCP, RTP_INP_RTCP_INITIALIZED, RTP_INP_CREATE_SENDER_MODULE, RTP_INP_SENDER_MODULE_CREATED, RTP_INP_DELETE_SENDER_MODULE, RTP_INP_SENDER_MODULE_DELETED, RTP_INP_INITIALIZE_SENDER_MODULE, RTP_INP_SENDER_MODULE_INITIALIZED, RTP_INP_SENDER_MODULE_CONTROL, RTP_INP_SENDER_MODULE_STATUS, RTP_INP_LEAVE_SESSION, RTP_INP_SESSION_LEFT, RTP_INP_DATA_OUT, RTP_INP_DATA_IN } |
Public Member Functions | |
RTPInnerPacket (const char *name=NULL) | |
RTPInnerPacket (const RTPInnerPacket &rinp) | |
virtual | ~RTPInnerPacket () |
RTPInnerPacket & | operator= (const RTPInnerPacket &rinp) |
virtual cObject * | dup () const |
virtual const char * | className () const |
virtual std::string | info () |
virtual void | writeContents (std::ostream &os) const |
virtual void | initializeProfile (int mtu) |
virtual void | profileInitialized (int rtcpPercentage, IN_Port port) |
virtual void | initializeRTCP (const char *commonName, int mtu, int bandwidth, int rtcpPercentage, IN_Addr address, IN_Port port) |
virtual void | rtcpInitialized (u_int32 ssrc) |
virtual void | createSenderModule (u_int32 ssrc, int payloadType, const char *fileName) |
virtual void | senderModuleCreated (u_int32 ssrc) |
virtual void | deleteSenderModule (u_int32 ssrc) |
virtual void | senderModuleDeleted (u_int32 ssrc) |
virtual void | initializeSenderModule (u_int32 ssrc, const char *fileName, int mtu) |
virtual void | senderModuleInitialized (u_int32 ssrc, int payloadType, int clockRate, int timeStampBase, int sequenceNumberBase) |
virtual void | senderModuleControl (u_int32 ssrc, RTPSenderControlMessage *msg) |
virtual void | senderModuleStatus (u_int32 ssrc, RTPSenderStatusMessage *msg) |
virtual void | leaveSession () |
virtual void | sessionLeft () |
virtual void | dataOut (RTPPacket *packet) |
virtual void | dataIn (RTPPacket *packet, IN_Addr address, IN_Port port) |
virtual RTP_INP_TYPE | type () |
virtual const char * | commonName () |
virtual int | mtu () |
virtual int | bandwidth () |
virtual int | rtcpPercentage () |
virtual IN_Addr | address () |
virtual IN_Port | port () |
virtual u_int32 | ssrc () |
virtual int | payloadType () |
virtual const char * | fileName () |
virtual int | clockRate () |
virtual int | timeStampBase () |
virtual int | sequenceNumberBase () |
Private Attributes | |
RTP_INP_TYPE | _type |
const char * | _commonName |
int | _mtu |
int | _bandwidth |
int | _rtcpPercentage |
IN_Addr | _address |
IN_Port | _port |
u_int32 | _ssrc |
int | _payloadType |
const char * | _fileName |
int | _clockRate |
int | _timeStampBase |
int | _sequenceNumberBase |
|
This enumeration is a list of all possibly types of an RTPInnerPacket.
00049 { 00050 RTP_INP_UNDEF, 00051 RTP_INP_INITIALIZE_PROFILE, 00052 RTP_INP_PROFILE_INITIALIZED, 00053 RTP_INP_INITIALIZE_RTCP, 00054 RTP_INP_RTCP_INITIALIZED, 00055 RTP_INP_CREATE_SENDER_MODULE, 00056 RTP_INP_SENDER_MODULE_CREATED, 00057 RTP_INP_DELETE_SENDER_MODULE, 00058 RTP_INP_SENDER_MODULE_DELETED, 00059 RTP_INP_INITIALIZE_SENDER_MODULE, 00060 RTP_INP_SENDER_MODULE_INITIALIZED, 00061 RTP_INP_SENDER_MODULE_CONTROL, 00062 RTP_INP_SENDER_MODULE_STATUS, 00063 RTP_INP_LEAVE_SESSION, 00064 RTP_INP_SESSION_LEFT, 00065 RTP_INP_DATA_OUT, 00066 RTP_INP_DATA_IN 00067 };
|
|
Default constructor 00032 : cPacket(name) { 00033 _type = RTP_INP_UNDEF; 00034 _commonName = NULL; 00035 _mtu = 0; 00036 _bandwidth = 0; 00037 _rtcpPercentage = 0; 00038 _address = IPADDRESS_UNDEF; 00039 _port = IPSuite_PORT_UNDEF; 00040 _ssrc = 0; 00041 _payloadType = 0; 00042 _fileName = NULL; 00043 _clockRate = 0; 00044 _timeStampBase = 0; 00045 _sequenceNumberBase = 0; 00046 };
|
|
Copy constructor. 00049 : cPacket() { 00050 setName(rinp.name()); 00051 operator=(rinp); 00052 };
|
|
Destructor. 00055 { 00056 if (opp_strcmp(_commonName, "")) 00057 delete _commonName; 00058 if (opp_strcmp(_fileName, "")) 00059 delete _fileName; 00060 };
|
|
Returns the address stored in this RTPInnerPacket. 00253 { 00254 return _address; 00255 };
|
|
Returns the available bandwitdth as stored in this RTPInnerPacket. 00243 { 00244 return _bandwidth; 00245 };
|
|
Returns the class name "RTPInnerPacket". 00087 { 00088 return "RTPInnerPacket"; 00089 };
|
|
Returns the rtp clock rate stored in this RTPInnerPacket. 00278 { 00279 return _clockRate; 00280 };
|
|
Returns the CNAME stored in this RTPInnerPacket. 00233 {
00234 return opp_strdup(_commonName);
00235 };
|
|
00147 { 00148 _type = RTP_INP_CREATE_SENDER_MODULE; 00149 _ssrc = ssrc; 00150 _payloadType = payloadType; 00151 _fileName = fileName; 00152 };
|
|
Capsultes the incoming RTPPacket into this RTPInnerPacket to transport it within the rtp layer. 00220 { 00221 _type = RTP_INP_DATA_IN; 00222 _address = address; 00223 _port = port; 00224 encapsulate(packet); 00225 };
|
|
Capsulates the outgoing RTPPacket into this RTPInnerPacket to transport it within the rtp layer. 00214 { 00215 _type = RTP_INP_DATA_OUT; 00216 encapsulate(packet); 00217 };
|
|
00161 { 00162 _type = RTP_INP_DELETE_SENDER_MODULE; 00163 _ssrc = ssrc; 00164 };
|
|
Duplicates the RTPInnerPacket by calling the copy constructor. 00082 { 00083 return new RTPInnerPacket(*this); 00084 };
|
|
Returns the file name stored in this RTPInnerPacket. 00268 {
00269 return opp_strdup(_fileName);
00270 };
|
|
Writes a short info about this RTPInnerPacket into the given string. 00092 { 00093 std::stringstream out; 00094 out << "RTPInnerPacket: type=" << _type; 00095 return out.str(); 00096 };
|
|
Called by the rtp module after creating the profile module. It informes the profile about the maximum size an rtp packet can have. 00117 { 00118 _type = RTP_INP_INITIALIZE_PROFILE; 00119 _mtu = mtu; 00120 };
|
|
Called by the rtp module to inform the rtcp module about mandatory information for starting the rtp session. 00130 { 00131 _type = RTP_INP_INITIALIZE_RTCP; 00132 _commonName = commonName; 00133 _mtu = mtu; 00134 _bandwidth = bandwidth; 00135 _rtcpPercentage = rtcpPercentage; 00136 _address = address; 00137 _port = port; 00138 };
|
|
00173 { 00174 _type = RTP_INP_INITIALIZE_SENDER_MODULE; 00175 _ssrc = ssrc; 00176 _fileName = fileName; 00177 _mtu = mtu; 00178 };
|
|
Called by the rtp module to inform the rtcp module that the session should be left. 00204 { 00205 _type = RTP_INP_LEAVE_SESSION; 00206 };
|
|
Returns the maximum transmission unit stored in this RTPInnerPacket. 00238 { 00239 return _mtu; 00240 };
|
|
Assignment operator. 00063 { 00064 cPacket::operator=(rinp); 00065 _type = rinp._type; 00066 _commonName = opp_strdup(rinp._commonName); 00067 _mtu = rinp._mtu; 00068 _bandwidth = rinp._bandwidth; 00069 _rtcpPercentage = rinp._rtcpPercentage; 00070 _address = rinp._address; 00071 _port = rinp._port; 00072 _ssrc = rinp._ssrc; 00073 _payloadType = rinp._payloadType; 00074 _fileName = opp_strdup(rinp._fileName); 00075 _clockRate = rinp._clockRate; 00076 _timeStampBase = rinp._timeStampBase; 00077 _sequenceNumberBase = rinp._sequenceNumberBase; 00078 return *this; 00079 };
|
|
Returns the payload type stored in this RTPInnerPacket. 00273 { 00274 return _payloadType; 00275 };
|
|
Returns the port stored in this RTPInnerPacket. 00258 { 00259 return _port; 00260 };
|
|
Called by the profile module after it has received the initializeProfile() message. It informs the rtp module about the percentage of the available bandwidth to be used by rtcp and the preferred port for this profile. 00123 { 00124 _type = RTP_INP_PROFILE_INITIALIZED; 00125 _rtcpPercentage = rtcpPercentage; 00126 _port = port; 00127 };
|
|
Called by the rtcp module after it has waited for half an rtcp interval for incoming messages from other session participants. It informs the rtp module which later informs the rtp application about the ssrc identifier 00141 { 00142 _type = RTP_INP_RTCP_INITIALIZED; 00143 _ssrc = ssrc; 00144 };
|
|
Returns the percentage of bandwidth for rtcp as stored in this RTPInnerPacket. 00248 { 00249 return _rtcpPercentage; 00250 };
|
|
00190 { 00191 _type = RTP_INP_SENDER_MODULE_CONTROL; 00192 _ssrc = ssrc; 00193 encapsulate(msg); 00194 };
|
|
00155 { 00156 _type = RTP_INP_SENDER_MODULE_CREATED; 00157 _ssrc = ssrc; 00158 };
|
|
00167 { 00168 _type = RTP_INP_SENDER_MODULE_DELETED; 00169 _ssrc = ssrc; 00170 };
|
|
00181 { 00182 _type = RTP_INP_SENDER_MODULE_INITIALIZED; 00183 _ssrc = ssrc; 00184 _payloadType = payloadType; 00185 _clockRate = clockRate; 00186 _timeStampBase = timeStampBase; 00187 _sequenceNumberBase = sequenceNumberBase; 00188 };
|
|
00197 { 00198 _type = RTP_INP_SENDER_MODULE_STATUS; 00199 _ssrc = ssrc; 00200 encapsulate(msg); 00201 };
|
|
Returns the rtp sequence number base stored in this RTPInnerPacket. 00288 { 00289 return _sequenceNumberBase; 00290 };
|
|
Called by the rtcp module when the rtcp bye packet has been sent to the network. 00209 { 00210 _type = RTP_INP_SESSION_LEFT; 00211 };
|
|
Returns the ssrc identifier stored in this RTPInnerPacket. 00263 { 00264 return _ssrc; 00265 };
|
|
Returns the rtp time stamp base stored in this RTPInnerPacket. 00283 { 00284 return _timeStampBase; 00285 };
|
|
Returns the type of this RTPInnerPacket. 00228 { 00229 return _type; 00230 };
|
|
Writes a longer info about this RTPInnerPacket into the given output stream. 00099 { 00100 os << "RTPInnerPacket:" << endl; 00101 os << " type = " << _type << endl; 00102 os << " commonName = " << _commonName << endl; 00103 os << " mtu = " << _mtu << endl; 00104 os << " bandwidth = " << _bandwidth << endl; 00105 os << " rtcpPercentage = " << _rtcpPercentage << endl; 00106 os << " address = " << _address << endl; 00107 os << " port = " << _port << endl; 00108 os << " ssrc = " << _ssrc << endl; 00109 os << " payloadType = " << _payloadType << endl; 00110 os << " fileName = " << _fileName << endl; 00111 os << " clockRate = " << _clockRate << endl; 00112 os << " timeStampBase = " << _timeStampBase << endl; 00113 os << " sequenceNumberBase = " << _sequenceNumberBase << endl; 00114 };
|
|
The address stored this RTPInnerPacket. |
|
The bandwidth stored in this RTPInnerPacket. |
|
The clock rate stored in this RTPInnerPacket. |
|
The CNAME stored in this RTPInnerPacket. |
|
The file name stored in this RTPInnerPacket. |
|
The mtu stored in this RTPInnerPacket. |
|
The payload type stored in this RTPInnerPacket. |
|
The port stored this RTPInnerPacket. |
|
The rtcp percentage stored in this RTPInnerPacket. |
|
The rtp sequence number base stored in this RTPInnerPacket. |
|
The ssrc identifier stored in this RTPInnerPacket. |
|
The rtp time stamp base stored in this RTPInnerPacket. |
|
The type of this RTPInnerPacket. |