source: flair-src/branches/mavlink/lib/FlairSensorActuator/src/unexported/VrpnClient_impl.h@ 98

Last change on this file since 98 was 16, checked in by Bayard Gildas, 8 years ago

Reformatting

File size: 2.1 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5// created: 2013/04/03
6// filename: VrpnClient_impl.h
7//
8// author: César Richard, Guillaume Sanahuja
9// Copyright Heudiasyc UMR UTC/CNRS 7253
10//
11// version: $Id: $
12//
13// purpose: objet se connectant au serveur vrpn
14//
15//
16/*********************************************************************/
17
18#ifndef VRPNCLIENT_IMPL_H
19#define VRPNCLIENT_IMPL_H
20
21#include <string>
22#include <vector>
23
24namespace flair {
25namespace core {
26class OneAxisRotation;
27class Vector3D;
28class Quaternion;
29class Mutex;
30class SerialPort;
31}
32namespace gui {
33class TabWidget;
34class Tab;
35class Layout;
36}
37namespace sensor {
38class VrpnClient;
39class VrpnObject;
40}
41}
42
43class VrpnObject_impl;
44class vrpn_Connection;
45
46class VrpnClient_impl {
47public:
48 VrpnClient_impl(flair::sensor::VrpnClient *self, std::string name,
49 std::string address, uint16_t us_period);
50 VrpnClient_impl(flair::sensor::VrpnClient *self, std::string name,
51 flair::core::SerialPort *serialport, uint16_t us_period);
52 ~VrpnClient_impl();
53 void AddTrackable(flair::sensor::VrpnObject *obj); // normal
54 void RemoveTrackable(flair::sensor::VrpnObject *obj); // normal
55 void AddTrackable(VrpnObject_impl *obj, uint8_t id); // xbee
56 void RemoveTrackable(VrpnObject_impl *obj); // xbee
57 void ComputeRotations(flair::core::Vector3D &point);
58 void ComputeRotations(flair::core::Quaternion &quat);
59 bool UseXbee(void);
60 void Run(void);
61 flair::gui::Tab *setup_tab;
62 flair::gui::TabWidget *tab;
63 vrpn_Connection *connection;
64
65private:
66 flair::sensor::VrpnClient *self;
67 flair::core::Mutex *mutex;
68 uint16_t us_period;
69 std::vector<flair::sensor::VrpnObject *> trackables;
70 typedef struct xbee_object {
71 VrpnObject_impl *vrpnobject;
72 uint8_t id;
73 } xbee_object;
74
75 std::vector<xbee_object> xbee_objects;
76 flair::gui::Tab *main_tab;
77 flair::core::OneAxisRotation *rotation_1, *rotation_2;
78 flair::core::SerialPort *serialport;
79};
80
81#endif // VRPNCLIENT_IMPL_H
Note: See TracBrowser for help on using the repository browser.