vrpn
07.33
Virtual Reality Peripheral Network
vrpn_Event_Mouse.h
Go to the documentation of this file.
1
/**************************************************************************************************/
2
/* */
3
/* Copyright (C) 2004 Bauhaus University Weimar */
4
/* Released into the public domain on 6/23/2007 as part of the VRPN project */
5
/* by Jan P. Springer. */
6
/* */
7
/**************************************************************************************************/
8
/* */
9
/* module : vrpn_Event_Mouse.h */
10
/* project : */
11
/* description: mouse input using the event interface */
12
/* */
13
/**************************************************************************************************/
14
15
16
#ifndef _VRPN_EVENT_MOUSE_H_
17
#define _VRPN_EVENT_MOUSE_H_
18
19
#include "
vrpn_Button.h
"
// for vrpn_Button_Server
20
#include "
vrpn_Configure.h
"
// for VRPN_API
21
// includes, project
22
#include "
vrpn_Event_Analog.h
"
// for vrpn_Event_Analog
23
#include "
vrpn_Shared.h
"
// for timeval
24
25
class
VRPN_API
vrpn_Connection
;
26
27
28
class
VRPN_API
vrpn_Event_Mouse
:
public
vrpn_Event_Analog
,
29
public
vrpn_Button_Server
30
{
31
32
public
:
33
34
// creates a vrpn_Event_Mouse
35
vrpn_Event_Mouse
(
const
char
*name,
vrpn_Connection
*c = 0,
36
const
char
* evdev_name =
"/dev/input/event0"
);
37
38
// default dtor
39
~
vrpn_Event_Mouse
();
40
41
// This routine is called each time through the server's main loop. It will
42
// read from the mouse.
43
void
mainloop
(
void
);
44
45
private
:
46
47
// This routine interpret data from the device
48
void
process_mouse_data ();
49
50
// set all buttons and analogs to 0
51
void
clear_values();
52
53
private
:
54
55
struct
timeval timestamp;
56
};
57
58
#endif // _VRPN_EVENT_MOUSE_H_
vrpn_Event_Analog
Definition:
vrpn_Event_Analog.h:28
vrpn_Event_Analog.h
vrpn_Button_Server
Definition:
vrpn_Button.h:98
vrpn_Shared.h
vrpn_Button_Server::mainloop
virtual void mainloop()
Called once each time through the server program's mainloop to handle various functions (like setting...
Definition:
vrpn_Button.C:470
vrpn_Button.h
vrpn_Connection
Generic connection class not specific to the transport mechanism.
Definition:
vrpn_Connection.h:510
vrpn_Event_Mouse
Definition:
vrpn_Event_Mouse.h:30
vrpn_Configure.h
VRPN_API
#define VRPN_API
Definition:
vrpn_Configure.h:646
vrpn_Event_Mouse.h
Generated by
1.8.18