Essentially a Manifold expressed in world coordinate terms. More...
#include <playrho/d2/WorldManifold.hpp>
Classes | |
struct | PointData |
Point data for world manifold. More... | |
Public Types | |
using | size_type = std::remove_const_t< decltype(MaxManifoldPoints)> |
Size type. | |
Public Member Functions | |
WorldManifold ()=default | |
constexpr | WorldManifold (const UnitVec &normal) noexcept |
Initializing constructor. More... | |
constexpr | WorldManifold (const UnitVec &normal, const PointData &ps0) noexcept |
Initializing constructor. More... | |
constexpr | WorldManifold (const UnitVec &normal, const PointData &ps0, const PointData &ps1) noexcept |
Initializing constructor. More... | |
Momentum2 | GetImpulses (size_type index) const noexcept |
Gets the given index contact impulses. More... | |
UnitVec | GetNormal () const noexcept |
Length2 | GetPoint (size_type index) const noexcept |
Gets the indexed point's location in world coordinates. More... | |
size_type | GetPointCount () const noexcept |
Gets the point count. More... | |
Length | GetSeparation (size_type index) const noexcept |
Gets the amount of separation at the given indexed point. More... | |
Essentially a Manifold expressed in world coordinate terms.
Used to recognize the current state of a contact manifold in world coordinates.
|
default |
Default constructor.
A default constructed world manifold will gave a point count of zero, an invalid normal, invalid points, and invalid separations.
|
inlineexplicitconstexprnoexcept |
Initializing constructor.
IsValid(normal)
is true.
|
inlineexplicitconstexprnoexcept |
Initializing constructor.
IsValid(normal)
is true.
|
inlineexplicitconstexprnoexcept |
Initializing constructor.
IsValid(normal)
is true. Gets the given index contact impulses.
index
is less than MaxManifoldPoints
. Referenced by playrho::d2::VelocityConstraint::VelocityConstraint().
|
inlinenoexcept |
Gets the normal of the contact.
This is a directional unit-vector.
Gets the indexed point's location in world coordinates.
index | Index to return point for. This must be between 0 and GetPointCount() to get a valid point from this function. |
index
is less than MaxManifoldPoints
. Referenced by playrho::d2::VelocityConstraint::VelocityConstraint().
|
inlinenoexcept |
Gets the point count.
This is the maximum index value that can be used to access valid point or separation information.
Referenced by playrho::d2::VelocityConstraint::VelocityConstraint().
Gets the amount of separation at the given indexed point.
index | Index to return separation for. This must be between 0 and GetPointCount() . |
index
is less than MaxManifoldPoints
.