OpenIndy-Core  0.2.0.43
position.h
Go to the documentation of this file.
1 #ifndef POSITION_H
2 #define POSITION_H
3 
4 #include <QObject>
5 
6 #include "element.h"
7 #include "oivec.h"
8 
9 namespace oi{
10 
11 using namespace math;
12 
17 {
18  Q_OBJECT
19 
20 public:
21  explicit Position(QObject *parent = 0);
22  explicit Position(const OiVec &v, QObject *parent = 0);
23  explicit Position(const double &x, const double &y, const double &z, const double &h = 1.0, QObject *parent = 0);
24 
25  Position(const Position &copy, QObject *parent = 0);
26 
27  Position &operator=(const Position &copy);
28 
29  ~Position();
30 
31  //##########################
32  //get or set position vector
33  //##########################
34 
35  void setVector(const OiVec &v);
36  void setVector(const double &x, const double &y, const double &z, const double &h = 1.0);
37 
38  const OiVec &getVector() const;
39  const OiVec &getVectorH() const;
40 
41 protected:
42  OiVec xyz; //vector of size 3 (x, y, z)
43  OiVec xyzH; //homogeneous vector of size 4 (x, y, z, h)
44 
45 };
46 
47 }
48 
49 #endif // POSITION_H
The Element class.
Definition: element.h:17
The Position class.
Definition: position.h:16
The OiVec class.
Definition: oivec.h:22
OiVec xyz
Definition: position.h:42
Definition: coordinatesystem.h:15
OiVec xyzH
Definition: position.h:43
#define OI_CORE_EXPORT
Definition: types.h:11