Table of Contents

Struct RigidPose

Namespace
BepuPhysics
Assembly
BepuPhysics.dll

Represents a rigid transformation.

public struct RigidPose
Inherited Members

Constructors

RigidPose(Vector3)

Creates a rigid pose with the given position and identity orientation.

public RigidPose(Vector3 position)

Parameters

position Vector3

Position of the pose.

RigidPose(Vector3, Quaternion)

Creates a rigid pose with the given position and orientation.

public RigidPose(Vector3 position, Quaternion orientation)

Parameters

position Vector3

Position of the pose.

orientation Quaternion

Orientation of the pose.

Fields

Orientation

Orientation of the pose.

public Quaternion Orientation

Field Value

Quaternion

Position

Position of the pose.

public Vector3 Position

Field Value

Vector3

Properties

Identity

Returns a pose with a position at (0,0,0) and identity orientation.

public static RigidPose Identity { get; }

Property Value

RigidPose

Methods

Invert(in RigidPose, out RigidPose)

Inverts the rigid transformation of the pose.

public static void Invert(in RigidPose pose, out RigidPose inverse)

Parameters

pose RigidPose

Pose to invert.

inverse RigidPose

Inverse of the pose.

MultiplyWithoutOverlap(in RigidPose, in RigidPose, out RigidPose)

Concatenates one rigid transform with another. The resulting transform is equivalent to performing transform a followed by transform b.

public static void MultiplyWithoutOverlap(in RigidPose a, in RigidPose b, out RigidPose result)

Parameters

a RigidPose

First transform to concatenate.

b RigidPose

Second transform to concatenate.

result RigidPose

Result of the concatenation.

ToString()

Returns a string representing the RigidPose as "Position, Orientation".

public override string ToString()

Returns

string

String representing the RigidPose.

Transform(Vector3, in RigidPose, out Vector3)

Transforms a vector by the rigid pose: v * pose.Orientation + pose.Position.

public static void Transform(Vector3 v, in RigidPose pose, out Vector3 result)

Parameters

v Vector3

Vector to transform.

pose RigidPose

Pose to transform the vector with.

result Vector3

Transformed vector.

TransformByInverse(Vector3, in RigidPose, out Vector3)

Transforms a vector by the inverse of a rigid pose: (v - pose.Position) * pose.Orientation^-1.

public static void TransformByInverse(Vector3 v, in RigidPose pose, out Vector3 result)

Parameters

v Vector3

Vector to transform.

pose RigidPose

Pose to invert and transform the vector with.

result Vector3

Transformed vector.

Operators

implicit operator RigidPose(Quaternion)

Creates a pose by treating a Quaternion as an orientation in the pose. Position is set to zero.

public static implicit operator RigidPose(Quaternion orientation)

Parameters

orientation Quaternion

Orientation to use in the pose.

Returns

RigidPose

implicit operator RigidPose(Vector3)

Creates a pose by treating a Vector3 as a position. Orientation is set to identity.

public static implicit operator RigidPose(Vector3 position)

Parameters

position Vector3

Position to use in the pose.

Returns

RigidPose

implicit operator RigidPose((Vector3 position, Quaternion orientation))

Creates a pose from a tuple of a position and orientation.

public static implicit operator RigidPose((Vector3 position, Quaternion orientation) poseComponents)

Parameters

poseComponents (Vector3 position, Quaternion orientation)

Position and orientation to use in the pose.

Returns

RigidPose