HDK
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
TIL_DeepSocketHandler.h
Go to the documentation of this file.
1
/*
2
* PROPRIETARY INFORMATION. This software is proprietary to
3
* Side Effects Software Inc., and is not to be reproduced,
4
* transmitted, or disclosed in any way without written permission.
5
*
6
* NAME: TIL_DeepSocketHandler.h ( TIL Library, C++)
7
*
8
* COMMENTS: This class handles reading the interface for reading an image
9
* from a socket. The class will read messages from the socket
10
* and send the data to the reader.
11
* The class assumes that the initial connection has been made and
12
* that the deep reader is configured to accept data.
13
*/
14
15
#ifndef __TIL_DeepSocketHandler__
16
#define __TIL_DeepSocketHandler__
17
18
#include "
TIL_API.h
"
19
#include <
UT/UT_NonCopyable.h
>
20
#include <
UT/UT_SysClone.h
>
21
22
class
UT_NetSocket
;
23
class
UT_NetPacket
;
24
class
TIL_DeepReader
;
25
26
class
TIL_API
TIL_DeepSocketHandler
27
{
28
public
:
29
TIL_DeepSocketHandler
(pid_t client,
30
UT_NetSocket
*socket,
31
TIL_DeepReader
*reader);
32
~
TIL_DeepSocketHandler
();
33
34
UT_NON_COPYABLE
(
TIL_DeepSocketHandler
)
35
36
int64
getMemoryUsage(
bool
inclusive)
const
;
37
38
int
getFileDescriptor()
const
;
39
UT_NetSocket
*
getSocket
() {
return
mySocket; }
40
41
int
processInput(
int
max_packets = 1e8);
42
bool
terminate(
bool
kill_proc =
true
);
43
void
setMousePosition(
float
mx,
float
my,
float
radius);
44
void
requestMaterialStyleSheet(
int
style_sheet_index);
45
void
autoUpdate();
46
void
halt();
47
48
private
:
49
void
clean();
50
bool
int32Message(
int32
*ival,
int
nints);
51
bool
fpreal32Message(
fpreal32
*fval,
int
nfloats);
52
53
UT_NetSocket
*mySocket;
54
UT_NetPacket
*myPacket;
55
TIL_DeepReader
*myReader;
56
pid_t myPid;
57
float
myMouseX;
58
float
myMouseY;
59
float
myMouseRadius;
60
bool
mySwapBytes;
61
};
62
63
#endif
TIL_DeepSocketHandler::getSocket
UT_NetSocket * getSocket()
Definition:
TIL_DeepSocketHandler.h:39
UT_NetSocket
Definition:
UT_NetSocket.h:38
int32
int int32
Definition:
SYS_Types.h:39
TIL_API.h
fpreal32
float fpreal32
Definition:
SYS_Types.h:200
UT_NON_COPYABLE
#define UT_NON_COPYABLE(CLASS)
Define deleted copy constructor and assignment operator inside a class.
Definition:
UT_NonCopyable.h:31
int64
long long int64
Definition:
SYS_Types.h:116
UT_NonCopyable.h
TIL_DeepSocketHandler
Definition:
TIL_DeepSocketHandler.h:26
TIL_DeepReader
Definition:
TIL_DeepReader.h:35
UT_NetPacket
Definition:
UT_NetPacket.h:38
TIL_API
#define TIL_API
Definition:
TIL_API.h:10
UT_SysClone.h
TIL
TIL_DeepSocketHandler.h
Generated on Fri Nov 8 2024 03:41:39 for HDK by
1.8.6