holoscan::Pose2

Beta
View as Markdown
template <typename K>
struct Pose2

Class representing 2D transformations (rigid body motion in 2D).

This class represents elements of the SE(2) group, which combines 2D rotations and translations. Each pose consists of a rotation component (SO2) and a translation vector in 2D space.

#include <holoscan/pose2.hpp>

Template parameters

K
typename

Scalar type (typically float or double).


Methods

inverse

Pose2 holoscan::Pose2<K>::inverse() const

Get the inverse transformation.

Returns: Inverse transformation.

matrix

Matrix3<K> holoscan::Pose2<K>::matrix() const

Get the 3×3 homogeneous transformation matrix representation.

Returns: 3×3 transformation matrix.

cast

template <typename S>
Pose2<S> holoscan::Pose2<K>::cast() const

Cast to a different scalar type.

Returns: Pose cast to the target type.

Template parameters

S
typename

Target scalar type.

pow

Pose2 holoscan::Pose2<K>::pow(
K exponent
) const

Compute the power of the transformation.

This computes the transformation raised to the given exponent using exponential coordinates and matrix exponentiation.

Returns: Transformation raised to the given power.

Parameters

exponent
K

Power to raise the transformation to.


Static methods

identity

static Pose2 holoscan::Pose2<K>::identity()

Create the identity transformation.

Returns: Identity transformation (no rotation or translation).

from_translation

static Pose2 holoscan::Pose2<K>::from_translation(
const Vector2<K> &translation
)

Create a pure translation transformation.

Returns: Translation-only transformation.

Parameters

translation
const Vector2<K> &

Translation vector.

from_rotation

static Pose2 holoscan::Pose2<K>::from_rotation(
const K angle
)

Create a pure rotation transformation.

Returns: Rotation-only transformation.

Parameters

angle
const K

Rotation angle in radians.

from_xy_a

static Pose2 holoscan::Pose2<K>::from_xy_a(
K px,
K py,
K angle
)

Create a pose from position and angle components.

Returns: Pose with specified translation and rotation.

Parameters

px
K

X component of translation.

py
K

Y component of translation.

angle
K

Rotation angle in radians.

from_matrix

static Pose2 holoscan::Pose2<K>::from_matrix(
const Matrix3<K> &matrix
)

Create a pose from a 3×3 transformation matrix.

Returns: Pose represented by the matrix.

Parameters

matrix
const Matrix3<K> &

3×3 Homogeneous transformation matrix.


Types

Typedefs

NameDefinition
ScalarK

Member variables

NameTypeDescription
kDimension static constexprint
rotationSO2< K >Rotation component.
translationVector2< K >Translation component.