TUIO C++ Developer API
UdpReceiver.h
1 /*
2  TUIO C++ Library
3  Copyright (c) 2005-2017 Martin Kaltenbrunner <martin@tuio.org>
4 
5  This library is free software; you can redistribute it and/or
6  modify it under the terms of the GNU Lesser General Public
7  License as published by the Free Software Foundation; either
8  version 3.0 of the License, or (at your option) any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public
16  License along with this library.
17 */
18 
19 #ifndef INCLUDED_UDPRECEIVER_H
20 #define INCLUDED_UDPRECEIVER_H
21 
22 #include "OscReceiver.h"
23 #include "ip/UdpSocket.h"
24 
25 namespace TUIO {
26 
33  class LIBDECL UdpReceiver: public OscReceiver {
34 
35  public:
36 
40  UdpListeningReceiveSocket *socket;
41 
47  UdpReceiver (int port=3333);
48 
52  virtual ~UdpReceiver();
53 
59  void connect(bool lock=false);
60 
64  void disconnect();
65 
66  private:
67 
68 #ifndef WIN32
69  pthread_t thread;
70 #else
71  HANDLE thread;
72 #endif
73 
74  bool locked;
75  };
76 };
77 #endif /* INCLUDED_UDPRECEIVER_H */
UdpListeningReceiveSocket * socket
Definition: UdpReceiver.h:40
Definition: UdpReceiver.h:33
Definition: FlashSender.h:166
Definition: OscReceiver.h:40