Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

RTPReflectorGM.h

Go to the documentation of this file.
00001 /* Copyright (C) 2000 KOM/Darmstadt University of Technology 00002 * 00003 * You are allowed to use all other parts of the code under the following terms: 00004 * 00005 * For non-commercial use, code may be used in unmodified form provided 00006 * that this copyright notice and this permission notice appear in 00007 * supporting documentation. 00008 * 00009 * This software is provided "as is" and without any express or implied 00010 * warranties, including, without limitation, the implied warranty of 00011 * fitness for a particular purpose. 00012 * 00013 * The code may be subjected to the GNU General Public License, Version 2, 00014 * and re-distributed under the terms of this license. 00015 * As a special exception, permission is granted to link this code 00016 * with the Qt library and distribute executables, as long as you 00017 * follow the requirements of the GNU GPL in regard to all of the 00018 * software in the executable aside from Qt. 00019 * 00020 * Commercial use other than under the terms of the GNU General Public 00021 * License is allowed only after express negotiation of conditions 00022 * with the authors. 00023 */ 00024 00025 00026 #ifndef RTPReflectorGM_H 00027 #define RTPReflectorGM_H 00028 00029 #include <sys/types.h> 00030 #include "var_type.h" 00031 00032 #include "MNSem.h" 00033 #include "MNMutex.h" 00034 00035 #include "MNRTPutildefs.h" 00036 00037 #include "ServerGM.h" 00038 00039 #include "MNFileSinkSH.h" 00040 #include "MNRTPSourceSH.h" 00041 #include "MNRTPDecoderSH.h" 00042 #include "MNPacketMultiplierSH.h" 00043 #include "MNRTPSinkSH.h" 00044 00049 class RTPReflectorGM : public ServerGM 00050 { 00051 SH::RTPSourceSH* _RTPSourceSH; 00052 SH::RTPSinkSH* _RTPSinkSH; 00053 00054 MediaState _streamer_state; 00055 MNSem _eof_sig; 00056 MNMutex _eof_lock; 00057 00058 MNString _client; 00059 MNString _server; 00060 00061 MNSocket* _local_down_rtp; 00062 MNSocket* _local_down_rtcp; 00063 MNSocket* _local_up_rtp; 00064 MNSocket* _local_up_rtcp; 00065 int _DistantPortDown; 00066 int _DistantPortUp; 00067 00068 public: 00069 RTPReflectorGM( GMUser* user, MNSelector& sel ); 00070 virtual ~RTPReflectorGM(); 00071 00072 virtual void init(int idx); 00073 00074 virtual void uninit(); 00075 virtual void set_hostnames( const MNString& Client, const MNString& Server ); 00076 virtual void set_ports( int idx, 00077 MNSocket* locDownRtp, 00078 MNSocket* locDownRtcp, 00079 int distDown, 00080 MNSocket* locUpRtp, 00081 MNSocket* locUpRtcp, 00082 int distUp ); 00083 virtual void start(); 00084 virtual bool graphManNotify( int idx, 00085 SH::Base* caller, 00086 SH::Notification attribute, 00087 void* msg ); 00088 private: 00089 virtual int start_streamer( int idx, int bandwidth ); 00090 public: 00091 virtual int open_file( int idx, 00092 const char* name , 00093 int rtp_pt, 00094 SDP::PayloadTypes int_pt, 00095 u_int32 bw, 00096 SDP::RetransTypes int_rt, 00097 int packetsize ); 00098 virtual int play( int startp, int stopp ); 00099 virtual int stop( ); 00100 virtual int pause( ); 00101 virtual int jump ( long pos ); 00102 }; 00103 00105 00106 #endif /* RTPReflectorGM_H */

Generated on Sun Mar 6 13:35:50 2005 for Komssys by doxygen 1.3.8