00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070 #ifndef __OPAL_H323RTP_H
00071 #define __OPAL_H323RTP_H
00072
00073 #ifdef P_USE_PRAGMA
00074 #pragma interface
00075 #endif
00076
00077
00078 #include "rtp.h"
00079
00080
00081 class H225_RTPSession;
00082
00083 class H245_TransportAddress;
00084 class H245_H2250LogicalChannelParameters;
00085 class H245_H2250LogicalChannelAckParameters;
00086
00087 class H323Connection;
00088 class H323_RTPChannel;
00089
00090
00091
00093
00096 class H323_RTP_Session : public RTP_UserData
00097 {
00098 PCLASSINFO(H323_RTP_Session, RTP_UserData);
00099
00108 virtual void OnTxStatistics(
00109 const RTP_Session & session
00110 ) const;
00111
00118 virtual void OnRxStatistics(
00119 const RTP_Session & session
00120 ) const;
00122
00127 virtual BOOL OnSendingPDU(
00128 const H323_RTPChannel & channel,
00129 H245_H2250LogicalChannelParameters & param
00130 ) const = 0;
00131
00135 virtual void OnSendingAckPDU(
00136 const H323_RTPChannel & channel,
00137 H245_H2250LogicalChannelAckParameters & param
00138 ) const = 0;
00139
00144 virtual BOOL OnReceivedPDU(
00145 H323_RTPChannel & channel,
00146 const H245_H2250LogicalChannelParameters & param,
00147 unsigned & errorCode
00148 ) = 0;
00149
00154 virtual BOOL OnReceivedAckPDU(
00155 H323_RTPChannel & channel,
00156 const H245_H2250LogicalChannelAckParameters & param
00157 ) = 0;
00158
00165 virtual void OnSendRasInfo(
00166 H225_RTPSession & info
00167 ) = 0;
00169
00170
00171 protected:
00176 H323_RTP_Session(
00177 const H323Connection & connection
00178 );
00180
00181 const H323Connection & connection;
00182 };
00183
00184
00187 class H323_RTP_UDP : public H323_RTP_Session
00188 {
00189 PCLASSINFO(H323_RTP_UDP, H323_RTP_Session);
00190
00191 public:
00196 H323_RTP_UDP(
00197 const H323Connection & connection,
00198 RTP_UDP & rtp,
00199 RTP_QOS * rtpqos = NULL
00200 );
00202
00207 virtual BOOL OnSendingPDU(
00208 const H323_RTPChannel & channel,
00209 H245_H2250LogicalChannelParameters & param
00210 ) const;
00211
00215 virtual void OnSendingAckPDU(
00216 const H323_RTPChannel & channel,
00217 H245_H2250LogicalChannelAckParameters & param
00218 ) const;
00219
00226 virtual BOOL OnReceivedPDU(
00227 H323_RTPChannel & channel,
00228 const H245_H2250LogicalChannelParameters & param,
00229 unsigned & errorCode
00230 );
00231
00238 virtual BOOL OnReceivedAckPDU(
00239 H323_RTPChannel & channel,
00240 const H245_H2250LogicalChannelAckParameters & param
00241 );
00242
00249 virtual void OnSendRasInfo(
00250 H225_RTPSession & info
00251 );
00253
00254 protected:
00255 virtual BOOL ExtractTransport(
00256 const H245_TransportAddress & pdu,
00257 BOOL isDataPort,
00258 unsigned & errorCode
00259 );
00260
00261 RTP_UDP & rtp;
00262 };
00263
00264
00265 #endif // __OPAL_H323RTP_H
00266
00267