Main MRPT website > C++ reference for MRPT 1.9.9
CObservationSkeleton.h
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | http://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2018, Individual contributors, see AUTHORS file |
6  | See: http://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See details in http://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 #ifndef CObservationSkeleton_H
10 #define CObservationSkeleton_H
11 
13 #include <mrpt/obs/CObservation.h>
14 #include <mrpt/poses/CPose3D.h>
15 #include <mrpt/poses/CPose2D.h>
16 
17 namespace mrpt
18 {
19 namespace obs
20 {
21 /** This class stores a skeleton as tracked by OPENNI2 & NITE2 libraries from
22  * PrimeSense sensors
23  *
24  * \sa CObservation
25  * \note Class introduced in MRPT 1.3.1
26  * \ingroup mrpt_obs_grp
27  */
29 {
31 
32  public:
33  /** Constructor.
34  */
36  : sensorPose(),
37  head(),
38  neck(),
39  torso(),
40  left_shoulder(),
41  left_elbow(),
42  left_hand(),
43  left_hip(),
44  left_knee(),
45  left_foot(),
47  right_elbow(),
48  right_hand(),
49  right_hip(),
50  right_knee(),
51  right_foot()
52  {
53  }
54 
55  /** Destructor
56  */
57  virtual ~CObservationSkeleton() {}
58  /** The pose of the sensor on the robot. */
60 
61  /** A generic joint for the skeleton observation */
63  {
64  /** Default constructor */
65  TSkeletonJoint() : x(.0), y(.0), z(.0), conf(.0) {}
66  /** 3D position */
67  double x, y, z;
68 
69  /** Confidence value [0...1] */
70  double conf;
71  };
72 
73  /** The skeleton joints (15)*/
77 
78  void getSensorPose(mrpt::poses::CPose3D& out_sensorPose) const override
79  {
80  out_sensorPose = sensorPose;
81  }
82  void setSensorPose(const mrpt::poses::CPose3D& newSensorPose) override
83  {
84  sensorPose = newSensorPose;
85  }
86  void getDescriptionAsText(std::ostream& o) const override;
87 
88 }; // End of class def.
89 
90 } // End of namespace
91 } // End of namespace
92 
93 #endif
mrpt::obs::CObservationSkeleton::TSkeletonJoint::TSkeletonJoint
TSkeletonJoint()
Default constructor.
Definition: CObservationSkeleton.h:65
mrpt::obs::CObservationSkeleton::CObservationSkeleton
CObservationSkeleton()
Constructor.
Definition: CObservationSkeleton.h:35
mrpt::obs::CObservationSkeleton::left_foot
TSkeletonJoint left_foot
Definition: CObservationSkeleton.h:75
mrpt::obs::CObservationSkeleton::left_elbow
TSkeletonJoint left_elbow
Definition: CObservationSkeleton.h:74
mrpt::obs::CObservationSkeleton::right_hip
TSkeletonJoint right_hip
Definition: CObservationSkeleton.h:76
mrpt
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
Definition: CKalmanFilterCapable.h:30
mrpt::obs::CObservationSkeleton::left_hip
TSkeletonJoint left_hip
Definition: CObservationSkeleton.h:75
CPose2D.h
mrpt::obs::CObservationSkeleton::right_elbow
TSkeletonJoint right_elbow
Definition: CObservationSkeleton.h:75
mrpt::obs::CObservationSkeleton::getDescriptionAsText
void getDescriptionAsText(std::ostream &o) const override
Build a detailed, multi-line textual description of the observation contents and dump it to the outpu...
Definition: CObservationSkeleton.cpp:91
mrpt::obs::CObservationSkeleton::head
TSkeletonJoint head
The skeleton joints (15)
Definition: CObservationSkeleton.h:74
mrpt::obs::CObservationSkeleton::left_hand
TSkeletonJoint left_hand
Definition: CObservationSkeleton.h:74
mrpt::obs::CObservationSkeleton::TSkeletonJoint::x
double x
3D position
Definition: CObservationSkeleton.h:67
mrpt::obs::CObservationSkeleton::TSkeletonJoint::y
double y
Definition: CObservationSkeleton.h:67
mrpt::poses::CPose3D
A class used to store a 3D pose (a 3D translation + a rotation in 3D).
Definition: CPose3D.h:88
mrpt::obs::CObservationSkeleton::right_knee
TSkeletonJoint right_knee
Definition: CObservationSkeleton.h:76
mrpt::obs::CObservationSkeleton::~CObservationSkeleton
virtual ~CObservationSkeleton()
Destructor.
Definition: CObservationSkeleton.h:57
CPose3D.h
mrpt::obs::CObservationSkeleton::right_shoulder
TSkeletonJoint right_shoulder
Definition: CObservationSkeleton.h:75
mrpt::obs::CObservationSkeleton::right_foot
TSkeletonJoint right_foot
Definition: CObservationSkeleton.h:76
mrpt::obs::CObservationSkeleton::sensorPose
mrpt::poses::CPose3D sensorPose
The pose of the sensor on the robot.
Definition: CObservationSkeleton.h:59
CObservation.h
DEFINE_SERIALIZABLE
#define DEFINE_SERIALIZABLE(class_name)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
Definition: CSerializable.h:102
mrpt::obs::CObservationSkeleton::TSkeletonJoint::conf
double conf
Confidence value [0...1].
Definition: CObservationSkeleton.h:70
mrpt::obs::CObservation
Declares a class that represents any robot's observation.
Definition: CObservation.h:43
mrpt::obs::CObservationSkeleton
This class stores a skeleton as tracked by OPENNI2 & NITE2 libraries from PrimeSense sensors.
Definition: CObservationSkeleton.h:28
z
GLdouble GLdouble z
Definition: glext.h:3872
mrpt::obs::CObservationSkeleton::TSkeletonJoint
A generic joint for the skeleton observation.
Definition: CObservationSkeleton.h:62
mrpt::obs::CObservationSkeleton::getSensorPose
void getSensorPose(mrpt::poses::CPose3D &out_sensorPose) const override
A general method to retrieve the sensor pose on the robot.
Definition: CObservationSkeleton.h:78
mrpt::obs::CObservationSkeleton::left_shoulder
TSkeletonJoint left_shoulder
Definition: CObservationSkeleton.h:74
mrpt::obs::CObservationSkeleton::setSensorPose
void setSensorPose(const mrpt::poses::CPose3D &newSensorPose) override
A general method to change the sensor pose on the robot.
Definition: CObservationSkeleton.h:82
mrpt::obs::CObservationSkeleton::neck
TSkeletonJoint neck
Definition: CObservationSkeleton.h:74
CSerializable.h
mrpt::obs::CObservationSkeleton::left_knee
TSkeletonJoint left_knee
Definition: CObservationSkeleton.h:75
mrpt::obs::CObservationSkeleton::TSkeletonJoint::z
double z
Definition: CObservationSkeleton.h:67
y
GLenum GLint GLint y
Definition: glext.h:3538
x
GLenum GLint x
Definition: glext.h:3538
mrpt::obs::CObservationSkeleton::torso
TSkeletonJoint torso
Definition: CObservationSkeleton.h:74
mrpt::obs::CObservationSkeleton::right_hand
TSkeletonJoint right_hand
Definition: CObservationSkeleton.h:75



Page generated by Doxygen 1.8.17 for MRPT 1.9.9 Git: ad3a9d8ae Tue May 1 23:10:22 2018 -0700 at miƩ 12 jul 2023 10:03:34 CEST