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

NopStreamer.h

Go to the documentation of this file.
00001 /* Copyright (C) 2002 Carsten Griwodz 00002 * 00003 * You are allowed to use all other parts of the code under the following terms: 00004 * 00005 * For non-commercial use, this code may be used in unmodified form 00006 * provided that this copyright notice and this permission notice appear 00007 * in supporting documentation. 00008 * 00009 * The code may be made subject to the terms of the GNU General Public 00010 * License, Version 2, and re-distributed under the terms of this license. 00011 * 00012 * Commercial use other than under the terms of the GNU General Public 00013 * License is allowed only after negotiation of conditions with the authors. 00014 */ 00015 #ifndef NOP_STREAMER_H 00016 #define NOP_STREAMER_H 00017 00018 #include "MNString.h" 00019 #include "MNSocket.h" 00020 #include "MNValid.h" 00021 #include "dataPump.h" 00022 #include "sdp/PayloadTypes.h" 00023 #include "sdp/RetransTypes.h" 00024 00025 class KomServer; 00026 00027 class MNUDPSocket; 00028 class SDPSessionDescription; 00029 00030 class NopStreamer : public dataPump 00031 { 00032 DECLARE_VALID 00033 private: 00035 NopStreamer( const NopStreamer& ); 00036 00038 NopStreamer& operator=( const NopStreamer& ); 00039 00040 public: 00042 NopStreamer( MNSelector& sel, 00043 DataPumpResponse* resp, 00044 SDPSessionDescription* sdesc ); 00045 00046 virtual ~NopStreamer ( ); 00047 00048 virtual int init ( KomServer* streamer, StreamingType type ); 00049 00054 virtual bool createUpstreamSocks( int idx, 00055 int& requested, 00056 RTPSockets::FactoryMode mode, 00057 RTSP::TransportTypes requested_transport = RTSP::RTP_AVP_UDP ); 00058 00063 virtual bool createDownstreamSocks( int idx, 00064 int& requested, 00065 RTPSockets::FactoryMode mode, 00066 RTSP::TransportTypes requested_transport = RTSP::RTP_AVP_UDP ); 00067 00068 00072 virtual MNSocket* getLocalDownRtp( int idx) const; 00073 virtual MNSocket* getLocalDownRtcp( int idx) const; 00074 virtual MNSocket* getLocalUpRtp( int idx) const; 00075 virtual MNSocket* getLocalUpRtcp( int idx) const; 00076 00080 virtual int getDistantPortDownstream( int idx) const; 00081 virtual int getDistantPortUpstream( int idx ) const; 00083 00087 virtual int getLocalPortDownstream( int idx) const; 00088 virtual int getLocalPortUpstream( int idx) const; 00090 00091 virtual bool fillTransportString( int idx, MNString& out, bool mc ) const; 00092 00093 virtual int stream_start ( int idx, 00094 const MNString& filename, 00095 const MNString& DescFileName, 00096 const MNString& client, 00097 const MNString& server, 00098 int ClientPortAnnounced, 00099 int ServerPortAnnounced ); 00100 virtual int play ( int start, int stop ); 00101 virtual int stop ( ); 00102 virtual int pause ( ); 00103 virtual int jump ( int cont_time ); 00104 virtual void fileComplete( const char* filename, bool comp ); 00105 virtual long getFilePos(); 00106 00107 virtual void set_client_port( int ) { } 00108 00109 virtual void setMulticastInformation( MNString server, 00110 MNSocket* main_rtp, 00111 MNSocket* main_rtcp ); 00112 virtual void setBufferInformation( int threshold, int size ); 00113 00114 virtual bool isPatchingCapable() const { return true; } 00115 00116 private: 00117 int* _upstream_rtp_created; 00118 int* _downstream_rtp_created; 00119 MNString _filename; 00120 }; 00121 00122 #endif /* NOP_STREAMER_H */ 00123

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