GAMS  1.4.0
gams::pose::Pose Class Reference

#include <Pose.h>

Inheritance diagram for gams::pose::Pose:
gams::pose::Framed< BasicPose< Pose > > gams::pose::BasicPose< Derived > gams::pose::PositionVector gams::pose::OrientationVector gams::pose::BasicVector< PositionVector, units::absolute< units::length > > gams::pose::BasicVector< OrientationVector, units::absolute< units::plane_angle > >

Public Types

using Base = Framed< BasicPose< Pose > >
 
typedef BasicPose BaseType
 
using derived_type = typename Impl::derived_type
 
using units_type = units::absolute< units::plane_angle >
 
using units_type = units::absolute< units::length >
 

Public Member Functions

 Pose ()=default
 
 Pose (const Orientation &ori)
 
 Pose (const Position &pos)
 
 Pose (const Position &pos, const Orientation &ori)
 
 Pose (const StampedOrientation &ori)
 
 Pose (const StampedPosition &pos)
 
 Pose (const StampedPosition &pos, const StampedOrientation &ori)
 
double angle_to (const Orientation &target) const
 Finds angle to the target; transforms target to this frame if needed. More...
 
template<typename U >
double angle_to (const Orientation &target, U u) const
 Finds angle to the target; transforms target to this frame if needed. More...
 
double angle_to (const Pose &target) const
 Finds angle to the target; transforms target to this frame if needed. More...
 
template<typename U >
double angle_to (const Pose &target, U u) const
 Finds angle to the target; transforms target to this frame if needed. More...
 
template<typename Derived2 >
bool approximately_equal (const BasicPose< Derived2 > &other, double epsilon) const
 Tests if this Coordinate is within epsilon in distance(as defined by this Coordinate's reference frame's distance metric). More...
 
bool approximately_equal (const Framed< Base2 > &other, double epsilon) const
 Tests if this Coordinate is within epsilon in distance (as defined by this Coordinate's reference frame's distance metric). More...
 
PositionVectoras_location_vec ()
 
const PositionVectoras_location_vec () const
 
OrientationVectoras_orientation_vec ()
 Gets a reference to this object's Orientation part. More...
 
const OrientationVectoras_orientation_vec () const
 Gets a const reference to this object's Orientation part. More...
 
PositionVectoras_position_vec ()
 Gets a reference to this object's Position part. More...
 
const PositionVectoras_position_vec () const
 Gets a const reference to this object's Position part. More...
 
BaseTypeas_vec ()
 Gets a reference to this object. More...
 
const BaseTypeas_vec () const
 Gets a const reference to this object. More...
 
PositionVector cross (const BasicVector< Other, units::absolute< units::length > > &other) const
 Passthrough to Eigen vector cross method. More...
 
OrientationVector cross (const BasicVector< Other, units::absolute< units::plane_angle > > &other) const
 Passthrough to Eigen vector cross method. More...
 
template<typename Derived2 >
double distance_to (const BasicPose< Derived2 > &target) const
 
double distance_to (const derived_type &target) const
 Calculate distance from this Coordinate to a target. More...
 
double dot (const BasicVector< Other, units::absolute< units::length > > &other) const
 Passthrough to Eigen vector dot method. More...
 
double dot (const BasicVector< Other, units::absolute< units::plane_angle > > &other) const
 Passthrough to Eigen vector dot method. More...
 
const ReferenceFrameframe () const
 Getter for the ReferenceFrame this Coordinate belongs to. More...
 
ReferenceFrame frame (ReferenceFrame new_frame)
 Setter for the ReferenceFrame this Coordinate belongs to. More...
 
void from_array (const ContainType &in)
 Overwrites this Coordinate's values with those pulled from the referenced array. More...
 
void from_array (const ContainType &in)
 Overwrites this Coordinate's values with those pulled from the referenced array. More...
 
void from_container (const madara::knowledge::containers::NativeDoubleVector &container)
 Imports the pose from a MADARA container. More...
 
void from_container (const std::vector< double > &container)
 Imports the pose from a STL vector container. More...
 
double get (int i) const
 Retrives i'th coordinate, 0-indexed, in order x, y, z, rx, ry, rz. More...
 
double get (size_t i) const
 Get i'th value in this Coordinate. More...
 
double get (size_t i) const
 Get i'th value in this Coordinate. More...
 
bool is_location_set () const
 
bool is_location_zero () const
 
bool is_orientation_set () const
 Tests if the orientation/orientation has been set. More...
 
bool is_orientation_zero () const
 Tests if all orientation information is zero. More...
 
bool is_position_set () const
 Tests if the position is set(valid). More...
 
bool is_position_zero () const
 Tests if all position information is zero. More...
 
bool is_set () const
 Tests if this Pose is invalid; i.e., any values are INVAL_COORD. More...
 
bool is_zero () const
 Tests if all pose information is zero. More...
 
double norm () const
 Passthrough to Eigen vector norm method. More...
 
double norm () const
 Passthrough to Eigen vector norm method. More...
 
void normalize ()
 Reduces this Coordinate to it's normalized form, should one exist. More...
 
OrientationVector normalized () const
 Passthrough to Eigen vector normalized method. More...
 
PositionVector normalized () const
 Passthrough to Eigen vector normalized method. More...
 
template<typename Derived2 >
 operator BasicVector< Derived2, units::absolute< units::length >> () const
 
template<typename Derived2 >
 operator BasicVector< Derived2, units::absolute< units::plane_angle >> () const
 
 operator Orientation () const
 Castig operator to extract Orientation from this Pose. More...
 
 operator Position () const
 Casting operator to extract Position from this Pose. More...
 
bool operator== (const BasicPose &rhs) const
 Tests for exact equality. More...
 
Derived & self ()
 
const Derived & self () const
 
double set (int i, double val)
 Sets i'th coordinate, 0-indexed, in order x, y, z, rx, ry, rz. More...
 
double set (size_t i, double v)
 Set i'th value in this Coordinate. More...
 
double set (size_t i, double v)
 Set i'th value in this Coordinate. More...
 
int size () const
 Get the number of values this coordinate type uses. More...
 
double squaredNorm () const
 Passthrough to Eigen vector squaredNorm method. More...
 
double squaredNorm () const
 Passthrough to Eigen vector squaredNorm method. More...
 
void to_array (ContainType &out) const
 Outputs this Coordinates values to the referenced container. More...
 
void to_array (ContainType &out) const
 Outputs this Coordinates values to the referenced container. More...
 
void to_container (madara::knowledge::containers::NativeDoubleVector &container) const
 Saves the pose to a MADARA container. More...
 
std::string to_string (const std::string &delimiter=", ", const std::string &unset_identifier="<unset>") const
 Returns a string of the values x, y, z, rx, ry, rz. More...
 
void transform_this_to (const ReferenceFrame &new_frame)
 Transform this coordinate, in place, to a new reference frame. More...
 
derived_type WARN_UNUSED transform_to (const ReferenceFrame &new_frame) const
 Copy and transform this coordinate to a new reference frame. More...
 

Static Public Member Functions

static constexpr bool fixed ()
 Is this coordinate a fixed vector? More...
 
static constexpr bool fixed ()
 Is this coordinate a fixed vector? More...
 
static constexpr bool free ()
 Is this coordinate a free vector? More...
 
static constexpr bool free ()
 Is this coordinate a free vector? More...
 
static std::string name ()
 Get the name of this coordinate type. More...
 
static constexpr bool positional ()
 Is this coordinate a positional one? More...
 
static constexpr bool rotational ()
 Is this coordinate a rotational one? More...
 

Static Public Attributes

static constexpr const char * type_name = "Pose"
 

Private Types

using mixin = typename unit_traits< units::absolute< units::length > >::template mixin< PositionVector >
 
using storage_mixin = typename unit_traits< units::absolute< units::length > >::storage_mixin
 
using traits = unit_traits< units::absolute< units::length > >
 

Private Attributes

ReferenceFrame frame_
 
Eigen::Vector3d vec_
 

Detailed Description

Definition at line 397 of file Pose.h.

Member Typedef Documentation

◆ Base

Definition at line 401 of file Pose.h.

◆ BaseType

template<typename Derived >
typedef BasicPose gams::pose::BasicPose< Derived >::BaseType
inherited

Definition at line 282 of file Pose.h.

◆ derived_type

using gams::pose::Framed< BasicPose< Pose > >::derived_type = typename Impl::derived_type
inherited

Definition at line 111 of file Framed.h.

◆ mixin

Definition at line 534 of file Coordinate.h.

◆ storage_mixin

◆ traits

◆ units_type [1/2]

◆ units_type [2/2]

Constructor & Destructor Documentation

◆ Pose() [1/7]

gams::pose::Pose::Pose ( )
default

◆ Pose() [2/7]

gams::pose::Pose::Pose ( const Position pos)
inline

Definition at line 408 of file Pose.h.

◆ Pose() [3/7]

gams::pose::Pose::Pose ( const StampedPosition pos)
inline

Definition at line 411 of file Pose.h.

◆ Pose() [4/7]

gams::pose::Pose::Pose ( const Orientation ori)
inline

Definition at line 414 of file Pose.h.

◆ Pose() [5/7]

gams::pose::Pose::Pose ( const StampedOrientation ori)
inline

Definition at line 417 of file Pose.h.

◆ Pose() [6/7]

gams::pose::Pose::Pose ( const Position pos,
const Orientation ori 
)
inline

Definition at line 420 of file Pose.h.

◆ Pose() [7/7]

gams::pose::Pose::Pose ( const StampedPosition pos,
const StampedOrientation ori 
)
inline

Definition at line 423 of file Pose.h.

Member Function Documentation

◆ angle_to() [1/4]

double gams::pose::Pose::angle_to ( const Orientation target) const

Finds angle to the target; transforms target to this frame if needed.

Parameters
targetthe target orientation
Returns
shortest angle to map this pose's onto the given orientation

◆ angle_to() [2/4]

template<typename U >
double gams::pose::Pose::angle_to ( const Orientation target,
u 
) const

Finds angle to the target; transforms target to this frame if needed.

Parameters
targetthe target orientation
Returns
shortest angle to map this pose's onto the given orientation

◆ angle_to() [3/4]

double gams::pose::Pose::angle_to ( const Pose target) const

Finds angle to the target; transforms target to this frame if needed.

Parameters
targetthe pose with the target orientation
Returns
shortest angle to map this pose's orientation onto the other pose

◆ angle_to() [4/4]

template<typename U >
double gams::pose::Pose::angle_to ( const Pose target,
u 
) const

Finds angle to the target; transforms target to this frame if needed.

Parameters
targetthe pose with the target orientation
Returns
shortest angle to map this pose's orientation onto the other pose

◆ approximately_equal() [1/2]

template<typename Derived >
template<typename Derived2 >
bool gams::pose::BasicPose< Derived >::approximately_equal ( const BasicPose< Derived2 > &  other,
double  epsilon 
) const
inlineinherited

Tests if this Coordinate is within epsilon in distance(as defined by this Coordinate's reference frame's distance metric).

If the other Coordinate is in a different reference frame, it is first copied, and converted to this Coordinate's reference frame.

Parameters
otherthe other Coordinate to test against
epsilonthe maximum distance permitted to return true
Returns
true if the distance is less than or equal to epsilon

Definition at line 339 of file Pose.h.

◆ approximately_equal() [2/2]

bool gams::pose::Framed< BasicPose< Pose > >::approximately_equal ( const Framed< Base2 > &  other,
double  epsilon 
) const
inlineinherited

Tests if this Coordinate is within epsilon in distance (as defined by this Coordinate's reference frame's distance metric).

If the other Coordinate is in a different reference frame, it is first copied, and converted to this Coordinate's reference frame.

Parameters
otherthe other Coordinate to test against
epsilonthe maximum distance permitted to return true
Returns
true if the distance is less than or equal to epsilon

Definition at line 208 of file Framed.h.

◆ as_location_vec() [1/2]

template<typename Derived >
PositionVector& gams::pose::BasicPose< Derived >::as_location_vec ( )
inherited

◆ as_location_vec() [2/2]

template<typename Derived >
const PositionVector& gams::pose::BasicPose< Derived >::as_location_vec ( ) const
inherited

◆ as_orientation_vec() [1/2]

template<typename Derived >
OrientationVector& gams::pose::BasicPose< Derived >::as_orientation_vec ( )
inherited

Gets a reference to this object's Orientation part.

Returns
reference to the OrientationVector

◆ as_orientation_vec() [2/2]

template<typename Derived >
const OrientationVector& gams::pose::BasicPose< Derived >::as_orientation_vec ( ) const
inherited

Gets a const reference to this object's Orientation part.

Returns
const reference to the OrientationVector

◆ as_position_vec() [1/2]

template<typename Derived >
PositionVector& gams::pose::BasicPose< Derived >::as_position_vec ( )
inherited

Gets a reference to this object's Position part.

Returns
reference to the PositionVector

◆ as_position_vec() [2/2]

template<typename Derived >
const PositionVector& gams::pose::BasicPose< Derived >::as_position_vec ( ) const
inherited

Gets a const reference to this object's Position part.

Returns
const reference to the PositionVector

◆ as_vec() [1/2]

template<typename Derived >
BaseType& gams::pose::BasicPose< Derived >::as_vec ( )
inherited

Gets a reference to this object.

Useful for derived types.

Returns
reference to this object.

◆ as_vec() [2/2]

template<typename Derived >
const BaseType& gams::pose::BasicPose< Derived >::as_vec ( ) const
inherited

Gets a const reference to this object.

Useful for derived types.

Returns
const reference to this object.

◆ cross() [1/2]

PositionVector gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::cross ( const BasicVector< Other, Units > &  other) const
inlineinherited

Passthrough to Eigen vector cross method.

Definition at line 714 of file Coordinate.h.

◆ cross() [2/2]

OrientationVector gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::cross ( const BasicVector< Other, Units > &  other) const
inlineinherited

Passthrough to Eigen vector cross method.

Definition at line 714 of file Coordinate.h.

◆ distance_to() [1/2]

template<typename Derived >
template<typename Derived2 >
double gams::pose::BasicPose< Derived >::distance_to ( const BasicPose< Derived2 > &  target) const
inlineinherited

Definition at line 349 of file Pose.h.

◆ distance_to() [2/2]

double gams::pose::Framed< BasicPose< Pose > >::distance_to ( const derived_type target) const
inherited

Calculate distance from this Coordinate to a target.

If the target is in another reference frame, this and the target will be copied, and converted to their closest common frame.

Requres "ReferenceFrame.h"

Parameters
targetthe target Coordinate to calculate distance to
Returns
the distance according to the distance metric in the common frame, for CoordType. Typically, return will be meters or degrees.
Exceptions
unrelated_framesthrown if the target's reference frame is not part of the same tree as the current one.
undefined_transformthrown if no conversion between two frames along the conversion path has been defined.

◆ dot() [1/2]

double gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::dot ( const BasicVector< Other, Units > &  other) const
inlineinherited

Passthrough to Eigen vector dot method.

Definition at line 705 of file Coordinate.h.

◆ dot() [2/2]

double gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::dot ( const BasicVector< Other, Units > &  other) const
inlineinherited

Passthrough to Eigen vector dot method.

Definition at line 705 of file Coordinate.h.

◆ fixed() [1/2]

static constexpr bool gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::fixed ( )
inlinestaticconstexprinherited

Is this coordinate a fixed vector?

Definition at line 561 of file Coordinate.h.

◆ fixed() [2/2]

static constexpr bool gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::fixed ( )
inlinestaticconstexprinherited

Is this coordinate a fixed vector?

Definition at line 561 of file Coordinate.h.

◆ frame() [1/2]

const ReferenceFrame& gams::pose::Framed< BasicPose< Pose > >::frame ( ) const
inlineinherited

Getter for the ReferenceFrame this Coordinate belongs to.

Returns
the frame

Definition at line 179 of file Framed.h.

◆ frame() [2/2]

ReferenceFrame gams::pose::Framed< BasicPose< Pose > >::frame ( ReferenceFrame  new_frame)
inlineinherited

Setter for the ReferenceFrame this Coordinate belongs to.

Any further calculations using this Coordinate will use this frame.

Not thread-safe.

Parameters
new_framethe frame the Coordinate will now belong to
Returns
the old frame

Definition at line 190 of file Framed.h.

◆ free() [1/2]

static constexpr bool gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::free ( )
inlinestaticconstexprinherited

Is this coordinate a free vector?

Definition at line 558 of file Coordinate.h.

◆ free() [2/2]

static constexpr bool gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::free ( )
inlinestaticconstexprinherited

Is this coordinate a free vector?

Definition at line 558 of file Coordinate.h.

◆ from_array() [1/2]

void gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::from_array ( const ContainType &  in)
inlineinherited

Overwrites this Coordinate's values with those pulled from the referenced array.

These values will be within this object's current reference frame. The container must support operator[],

If the array's size is smaller than the cardinality of this coordinate type, the behavior is undefined. If it is larger, the extra elements are ignored.

Template Parameters
ContainTypethe type of the container; must support operator[]
Parameters
inthe container to pull new values from.

Definition at line 637 of file Coordinate.h.

◆ from_array() [2/2]

void gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::from_array ( const ContainType &  in)
inlineinherited

Overwrites this Coordinate's values with those pulled from the referenced array.

These values will be within this object's current reference frame. The container must support operator[],

If the array's size is smaller than the cardinality of this coordinate type, the behavior is undefined. If it is larger, the extra elements are ignored.

Template Parameters
ContainTypethe type of the container; must support operator[]
Parameters
inthe container to pull new values from.

Definition at line 637 of file Coordinate.h.

◆ from_container() [1/2]

template<typename Derived >
void gams::pose::BasicPose< Derived >::from_container ( const madara::knowledge::containers::NativeDoubleVector &  container)
inherited

Imports the pose from a MADARA container.

Parameters
containerthe container to import from

◆ from_container() [2/2]

template<typename Derived >
void gams::pose::BasicPose< Derived >::from_container ( const std::vector< double > &  container)
inherited

Imports the pose from a STL vector container.

Parameters
containerthe container to import from

◆ get() [1/3]

template<typename Derived >
double gams::pose::BasicPose< Derived >::get ( int  i) const
inherited

Retrives i'th coordinate, 0-indexed, in order x, y, z, rx, ry, rz.

Parameters
ithe index
Returns
the i'th coordinate value
Exceptions
std::range_errorif index is less than 0, or greater than 6

◆ get() [2/3]

double gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::get ( size_t  i) const
inlineinherited

Get i'th value in this Coordinate.

No range checking!

Definition at line 569 of file Coordinate.h.

◆ get() [3/3]

double gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::get ( size_t  i) const
inlineinherited

Get i'th value in this Coordinate.

No range checking!

Definition at line 569 of file Coordinate.h.

◆ is_location_set()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_location_set ( ) const
inherited

◆ is_location_zero()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_location_zero ( ) const
inherited

◆ is_orientation_set()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_orientation_set ( ) const
inherited

Tests if the orientation/orientation has been set.

Returns
true if orientation has been set to something valid

◆ is_orientation_zero()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_orientation_zero ( ) const
inherited

Tests if all orientation information is zero.

Returns
true if all orientation information is zero

◆ is_position_set()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_position_set ( ) const
inherited

Tests if the position is set(valid).

Returns
true if position has been set to something valid

◆ is_position_zero()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_position_zero ( ) const
inherited

Tests if all position information is zero.

Returns
true if all position information is zero

◆ is_set()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_set ( ) const
inherited

Tests if this Pose is invalid; i.e., any values are INVAL_COORD.

Returns
true if at least one value is INVAL_COORD

◆ is_zero()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::is_zero ( ) const
inherited

Tests if all pose information is zero.

If true, is_position_zero and is_orientation_zero are also true

Returns
true if all pose information is zero

◆ name()

template<typename Derived >
static std::string gams::pose::BasicPose< Derived >::name ( )
staticinherited

Get the name of this coordinate type.

Returns
"Pose"

◆ norm() [1/2]

double gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::norm ( ) const
inlineinherited

Passthrough to Eigen vector norm method.

Definition at line 724 of file Coordinate.h.

◆ norm() [2/2]

double gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::norm ( ) const
inlineinherited

Passthrough to Eigen vector norm method.

Definition at line 724 of file Coordinate.h.

◆ normalize()

void gams::pose::Framed< BasicPose< Pose > >::normalize ( )
inherited

Reduces this Coordinate to it's normalized form, should one exist.

Typically useful for Coordinate types which incorporate angles.

Requres "ReferenceFrame.h"

◆ normalized() [1/2]

Passthrough to Eigen vector normalized method.

Definition at line 740 of file Coordinate.h.

◆ normalized() [2/2]

Passthrough to Eigen vector normalized method.

Definition at line 740 of file Coordinate.h.

◆ operator BasicVector< Derived2, units::absolute< units::length >>()

template<typename Derived >
template<typename Derived2 >
gams::pose::BasicPose< Derived >::operator BasicVector< Derived2, units::absolute< units::length >> ( ) const
inlineinherited

Definition at line 151 of file Pose.h.

◆ operator BasicVector< Derived2, units::absolute< units::plane_angle >>()

template<typename Derived >
template<typename Derived2 >
gams::pose::BasicPose< Derived >::operator BasicVector< Derived2, units::absolute< units::plane_angle >> ( ) const
inlineinherited

Definition at line 157 of file Pose.h.

◆ operator Orientation()

gams::pose::Pose::operator Orientation ( ) const

Castig operator to extract Orientation from this Pose.

Returns
Orientation with same frame as this pose, and same rx/ry/rz values

◆ operator Position()

gams::pose::Pose::operator Position ( ) const

Casting operator to extract Position from this Pose.

Returns
Position with same frame as this pose, and same x/y/z values

◆ operator==()

template<typename Derived >
bool gams::pose::BasicPose< Derived >::operator== ( const BasicPose< Derived > &  rhs) const
inherited

Tests for exact equality.

Parameters
rhsthe other pose to test against
Returns
true if all values equal corresponding values in other pose

◆ positional()

template<typename Derived >
static constexpr bool gams::pose::BasicPose< Derived >::positional ( )
inlinestaticconstexprinherited

Is this coordinate a positional one?

Definition at line 142 of file Pose.h.

◆ rotational()

template<typename Derived >
static constexpr bool gams::pose::BasicPose< Derived >::rotational ( )
inlinestaticconstexprinherited

Is this coordinate a rotational one?

Definition at line 145 of file Pose.h.

◆ self() [1/2]

template<typename Derived >
Derived& gams::pose::BasicPose< Derived >::self ( )
inlineinherited

Definition at line 147 of file Pose.h.

◆ self() [2/2]

template<typename Derived >
const Derived& gams::pose::BasicPose< Derived >::self ( ) const
inlineinherited

Definition at line 148 of file Pose.h.

◆ set() [1/3]

template<typename Derived >
double gams::pose::BasicPose< Derived >::set ( int  i,
double  val 
)
inherited

Sets i'th coordinate, 0-indexed, in order x, y, z, rx, ry, rz.

Parameters
ithe index
valthe new value
Returns
the new i'th coordinate value
Exceptions
std::range_errorif index is less than 0, or greater than 6

◆ set() [2/3]

double gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::set ( size_t  i,
double  v 
)
inlineinherited

Set i'th value in this Coordinate.

No range checking!

Parameters
ithe index of the coordinate
vthe value to set to
Returns
the new value

Definition at line 578 of file Coordinate.h.

◆ set() [3/3]

double gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::set ( size_t  i,
double  v 
)
inlineinherited

Set i'th value in this Coordinate.

No range checking!

Parameters
ithe index of the coordinate
vthe value to set to
Returns
the new value

Definition at line 578 of file Coordinate.h.

◆ size()

template<typename Derived >
int gams::pose::BasicPose< Derived >::size ( ) const
inherited

Get the number of values this coordinate type uses.

Returns
6

◆ squaredNorm() [1/2]

double gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::squaredNorm ( ) const
inlineinherited

Passthrough to Eigen vector squaredNorm method.

Definition at line 732 of file Coordinate.h.

◆ squaredNorm() [2/2]

double gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::squaredNorm ( ) const
inlineinherited

Passthrough to Eigen vector squaredNorm method.

Definition at line 732 of file Coordinate.h.

◆ to_array() [1/2]

void gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::to_array ( ContainType &  out) const
inlineinherited

Outputs this Coordinates values to the referenced container.

This container type must support operator[] for setting by index.

If the array's size is smaller than the cardinality of this coordinate type, the behavior is undefined. If it is larger, the extra elements are not changed.

The MADARA DoubleVector and NativeDoubleVector types are supported.

Template Parameters
ContainTypethe type of the container; must support "set"
Parameters
outthe container to put this Coordinate's values into.

Definition at line 616 of file Coordinate.h.

◆ to_array() [2/2]

void gams::pose::BasicVector< OrientationVector , units::absolute< units::plane_angle > >::to_array ( ContainType &  out) const
inlineinherited

Outputs this Coordinates values to the referenced container.

This container type must support operator[] for setting by index.

If the array's size is smaller than the cardinality of this coordinate type, the behavior is undefined. If it is larger, the extra elements are not changed.

The MADARA DoubleVector and NativeDoubleVector types are supported.

Template Parameters
ContainTypethe type of the container; must support "set"
Parameters
outthe container to put this Coordinate's values into.

Definition at line 616 of file Coordinate.h.

◆ to_container()

template<typename Derived >
void gams::pose::BasicPose< Derived >::to_container ( madara::knowledge::containers::NativeDoubleVector &  container) const
inherited

Saves the pose to a MADARA container.

Parameters
containerthe container to save to

◆ to_string()

template<typename Derived >
std::string gams::pose::BasicPose< Derived >::to_string ( const std::string &  delimiter = ", ",
const std::string &  unset_identifier = "<unset>" 
) const
inherited

Returns a string of the values x, y, z, rx, ry, rz.

Parameters
delimiterdelimiter between values
unset_identifierif true, include unset values
Returns
stringified version of the Pose

◆ transform_this_to()

void gams::pose::Framed< BasicPose< Pose > >::transform_this_to ( const ReferenceFrame new_frame)
inherited

Transform this coordinate, in place, to a new reference frame.

Requres "ReferenceFrame.h"

Parameters
new_framethe frame to transform to
Exceptions
unrelated_framesthrown if the new reference frame is not part of the same tree as the current one.
undefined_transformthrown if no conversion between two frames along the conversion path has been defined.

◆ transform_to()

derived_type WARN_UNUSED gams::pose::Framed< BasicPose< Pose > >::transform_to ( const ReferenceFrame new_frame) const
inherited

Copy and transform this coordinate to a new reference frame.

Requres "ReferenceFrame.h"

Parameters
new_framethe frame to transform to
Returns
the new coordinate in the new frame
Exceptions
unrelated_framesthrown if the new reference frame is not part of the same tree as the current one.
undefined_transformthrown if no conversion between two frames along the conversion path has been defined.

Member Data Documentation

◆ frame_

ReferenceFrame gams::pose::Framed< BasicPose< Pose > >::frame_
privateinherited

Definition at line 278 of file Framed.h.

◆ type_name

constexpr const char* gams::pose::Pose::type_name = "Pose"
staticconstexpr

Definition at line 404 of file Pose.h.

◆ vec_

Eigen::Vector3d gams::pose::BasicVector< PositionVector , units::absolute< units::length > >::vec_
privateinherited

Definition at line 530 of file Coordinate.h.


The documentation for this class was generated from the following file: