Pose Class Reference

Class containing positional tracking data giving the position and orientation of the camera in 3D space. More...

Functions

 Pose ()
 Default constructor. More...
 
 Pose (const Pose &pose)
 Copy constructor (deep copy). More...
 
 Pose (const Transform &pose_data, unsigned long long timestamp=0, int confidence=0)
 Constructor. More...
 
 ~Pose ()
 Default destructor. More...
 
Translation getTranslation () const
 Returns the sl::Translation corresponding to the current sl::Pose. More...
 
Orientation getOrientation () const
 Returns the sl::Orientation corresponding to the current sl::Pose. More...
 
Rotation getRotationMatrix () const
 Returns the sl::Rotation corresponding to the current sl::Pose. More...
 
float3 getRotationVector () const
 Returns the 3x1 rotation vector (obtained from 3x3 rotation matrix using Rodrigues formula) corresponding to the current sl::Pose. More...
 
float3 getEulerAngles (bool radian=true) const
 Converts the rotation component of the sl::Pose into Euler angles. More...
 

Attributes

Transform pose_data
 sl::Transform containing the rotation and translation data of the sl::Pose. More...
 
sl::Timestamp timestamp
 sl::Timestamp of the sl::Pose. More...
 
int pose_confidence
 Confidence/quality of the pose estimation for the target frame. More...
 
float pose_covariance [36]
 6x6 pose covariance matrix of translation (the first 3 values) and rotation in so3 (the last 3 values). More...
 
bool valid
 Whether the tracking is activated or not. More...
 
float twist [6]
 Twist of the camera available in reference camera. More...
 
float twist_covariance [36]
 Row-major representation of the 6x6 twist covariance matrix of the camera. More...
 

Detailed Description

Class containing positional tracking data giving the position and orientation of the camera in 3D space.

Different representations of position and orientation can be retrieved, along with timestamp and pose confidence.

Constructor and Destructor

◆ Pose() [1/3]

Pose ( )

Default constructor.

Creates an empty sl::Pose (identity).

◆ Pose() [2/3]

Pose ( const Pose pose)

Copy constructor (deep copy).

◆ Pose() [3/3]

Pose ( const Transform pose_data,
unsigned long long  timestamp = 0,
int  confidence = 0 
)

Constructor.

Initializes the transform of the sl::Pose with a sl::Transform (deep copy).

◆ ~Pose()

~Pose ( )

Default destructor.

Functions

◆ getTranslation()

Translation getTranslation ( ) const

Returns the sl::Translation corresponding to the current sl::Pose.

Returns
sl::Translation created from the sl::Pose values.

◆ getOrientation()

Orientation getOrientation ( ) const

Returns the sl::Orientation corresponding to the current sl::Pose.

Returns
sl::Orientation created from the sl::Pose values.

◆ getRotationMatrix()

Rotation getRotationMatrix ( ) const

Returns the sl::Rotation corresponding to the current sl::Pose.

Returns
sl::Rotation created from the sl::Pose values.

◆ getRotationVector()

float3 getRotationVector ( ) const

Returns the 3x1 rotation vector (obtained from 3x3 rotation matrix using Rodrigues formula) corresponding to the current sl::Pose.

Returns
Rotation vector created from the sl::Pose values.

◆ getEulerAngles()

float3 getEulerAngles ( bool  radian = true) const

Converts the rotation component of the sl::Pose into Euler angles.

Parameters
radian: Whether the angle will be returned in radian or degree.
Returns
Euler angles created from the sl::Pose values as a sl::float3 representing the rotations around the X, Y and Z axes using YZX convention.

Variables

◆ pose_data

Transform pose_data

sl::Transform containing the rotation and translation data of the sl::Pose.

◆ timestamp

sl::Timestamp timestamp

sl::Timestamp of the sl::Pose.

This timestamp should be compared with the camera timestamp for synchronization.

◆ pose_confidence

int pose_confidence

Confidence/quality of the pose estimation for the target frame.

A confidence metric of the tracking [0-100] with:

  • 0: tracking is lost
  • 100: tracking can be fully trusted

◆ pose_covariance

float pose_covariance[36]

6x6 pose covariance matrix of translation (the first 3 values) and rotation in so3 (the last 3 values).

◆ valid

bool valid

Whether the tracking is activated or not.

Note
You should check that first if something is wrong.

◆ twist

float twist[6]

Twist of the camera available in reference camera.

This expresses velocity in free space, broken into its linear and angular parts.

◆ twist_covariance

float twist_covariance[36]

Row-major representation of the 6x6 twist covariance matrix of the camera.

This expresses the uncertainty of the twist.