00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00025
00026 #ifndef RemoteUDPServer_H
00027 #define RemoteUDPServer_H
00028
00029
00030 #include "H3DNetworkingUtils/RemoteServer.h"
00031 #include "H3DNetworkingUtils/lockwrap.h"
00032
00033 namespace H3DNetworkingUtils {
00034
00047
00055
00061
00062 class H3D_NETWORKING_UTILS_DLL_SPEC RemoteUDPServer : public RemoteServer {
00063 public:
00064
00066 RemoteUDPServer();
00067
00069 virtual ~RemoteUDPServer();
00070
00072 static H3D::H3DNodeDatabase database;
00073
00074 protected:
00075
00077 virtual void sendThisPacket(Packet & packet);
00078
00080 virtual void receiveLoop ();
00081
00083 virtual void sendLoop();
00084
00086 virtual void startServer(int port_number);
00087
00088 private:
00089 InetAddr remote_end;
00090 Packet pulse_packet;
00091 Mutex send_packet_lock;
00092 double accumulated_time_to_kill;
00093 };
00094
00095 }
00096
00097 #endif