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
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089 #ifndef __OPAL_H323RTP_H
00090 #define __OPAL_H323RTP_H
00091
00092 #ifdef P_USE_PRAGMA
00093 #pragma interface
00094 #endif
00095
00096
00097 #include <rtp/rtp.h>
00098
00099
00100 class H225_RTPSession;
00101
00102 class H245_TransportAddress;
00103 class H245_H2250LogicalChannelParameters;
00104 class H245_H2250LogicalChannelAckParameters;
00105
00106 class H323Connection;
00107 class H323_RTPChannel;
00108
00109
00111
00114 class H323_RTP_Session : public RTP_UserData
00115 {
00116 PCLASSINFO(H323_RTP_Session, RTP_UserData);
00117
00126 virtual void OnTxStatistics(
00127 const RTP_Session & session
00128 ) const;
00129
00136 virtual void OnRxStatistics(
00137 const RTP_Session & session
00138 ) const;
00140
00145 virtual BOOL OnSendingPDU(
00146 const H323_RTPChannel & channel,
00147 H245_H2250LogicalChannelParameters & param
00148 ) const = 0;
00149
00153 virtual void OnSendingAckPDU(
00154 const H323_RTPChannel & channel,
00155 H245_H2250LogicalChannelAckParameters & param
00156 ) const = 0;
00157
00162 virtual BOOL OnReceivedPDU(
00163 H323_RTPChannel & channel,
00164 const H245_H2250LogicalChannelParameters & param,
00165 unsigned & errorCode
00166 ) = 0;
00167
00172 virtual BOOL OnReceivedAckPDU(
00173 H323_RTPChannel & channel,
00174 const H245_H2250LogicalChannelAckParameters & param
00175 ) = 0;
00176
00183 virtual void OnSendRasInfo(
00184 H225_RTPSession & info
00185 ) = 0;
00187
00188
00189 protected:
00194 H323_RTP_Session(
00195 const H323Connection & connection
00196 );
00198
00199 const H323Connection & connection;
00200 };
00201
00202
00205 class H323_RTP_UDP : public H323_RTP_Session
00206 {
00207 PCLASSINFO(H323_RTP_UDP, H323_RTP_Session);
00208
00209 public:
00214 H323_RTP_UDP(
00215 const H323Connection & connection,
00216 RTP_UDP & rtp
00217 );
00219
00224 virtual BOOL OnSendingPDU(
00225 const H323_RTPChannel & channel,
00226 H245_H2250LogicalChannelParameters & param
00227 ) const;
00228
00232 virtual void OnSendingAckPDU(
00233 const H323_RTPChannel & channel,
00234 H245_H2250LogicalChannelAckParameters & param
00235 ) const;
00236
00243 virtual BOOL OnReceivedPDU(
00244 H323_RTPChannel & channel,
00245 const H245_H2250LogicalChannelParameters & param,
00246 unsigned & errorCode
00247 );
00248
00255 virtual BOOL OnReceivedAckPDU(
00256 H323_RTPChannel & channel,
00257 const H245_H2250LogicalChannelAckParameters & param
00258 );
00259
00266 virtual void OnSendRasInfo(
00267 H225_RTPSession & info
00268 );
00270
00271 protected:
00272 virtual BOOL ExtractTransport(
00273 const H245_TransportAddress & pdu,
00274 BOOL isDataPort,
00275 unsigned & errorCode
00276 );
00277
00278 RTP_UDP & rtp;
00279 };
00280
00281
00282 #endif // __OPAL_H323RTP_H
00283
00284