The path for a path constraint. It allows attaching two bodies to each other while giving the second body the freedom to move along a path relative to the first.
More...
#include <PathConstraintPath.h>
|
virtual void | RestoreBinaryState (StreamIn &inStream) |
| This function should not be called directly, it is used by sRestoreFromBinaryState.
|
|
|
atomic< uint32 > | mRefCount |
| Current reference count.
|
|
static constexpr uint32 | cEmbedded |
| A large value that gets added to the refcount to mark the object as embedded.
|
|
The path for a path constraint. It allows attaching two bodies to each other while giving the second body the freedom to move along a path relative to the first.
◆ PathResult
◆ ~PathConstraintPath()
virtual PathConstraintPath::~PathConstraintPath |
( |
| ) |
|
|
overridevirtualdefault |
Virtual destructor to ensure that derived types get their destructors called.
◆ DrawPath()
Draw the path relative to inBaseTransform. Used for debug purposes.
◆ GetClosestPoint()
virtual float PathConstraintPath::GetClosestPoint |
( |
Vec3Arg | inPosition | ) |
const |
|
pure virtual |
Get the globally closest point on the curve (Could be slow!)
- Parameters
-
inPosition | Position to find closest point for |
- Returns
- Fraction of closest point along the path
Implemented in PathConstraintPathHermite.
◆ GetPathMaxFraction()
virtual float PathConstraintPath::GetPathMaxFraction |
( |
| ) |
const |
|
pure virtual |
◆ GetPointOnPath()
virtual void PathConstraintPath::GetPointOnPath |
( |
float | inFraction, |
|
|
Vec3 & | outPathPosition, |
|
|
Vec3 & | outPathTangent, |
|
|
Vec3 & | outPathNormal, |
|
|
Vec3 & | outPathBinormal ) const |
|
pure virtual |
Given the fraction along the path, get the point, tangent and normal.
- Parameters
-
inFraction | Fraction along the path [0, GetPathMaxFraction()]. |
outPathPosition | Returns the closest position to inSearchPosition on the path. |
outPathTangent | Returns the tangent to the path at outPathPosition (the vector that follows the direction of the path) |
outPathNormal | Return the normal to the path at outPathPosition (a vector that's perpendicular to outPathTangent) |
outPathBinormal | Returns the binormal to the path at outPathPosition (a vector so that normal cross tangent = binormal) |
Implemented in PathConstraintPathHermite.
◆ IsLooping()
bool PathConstraintPath::IsLooping |
( |
| ) |
const |
|
inline |
◆ RestoreBinaryState()
void PathConstraintPath::RestoreBinaryState |
( |
StreamIn & | inStream | ) |
|
|
protectedvirtual |
This function should not be called directly, it is used by sRestoreFromBinaryState.
Reimplemented in PathConstraintPathHermite.
◆ SaveBinaryState()
void PathConstraintPath::SaveBinaryState |
( |
StreamOut & | inStream | ) |
const |
|
virtual |
◆ SetIsLooping()
void PathConstraintPath::SetIsLooping |
( |
bool | inIsLooping | ) |
|
|
inline |
If the path is looping or not. If a path is looping, the first and last point are automatically connected to eachother. They should not be the same points.
◆ sRestoreFromBinaryState()
Creates a Shape of the correct type and restores its contents from the binary stream inStream.
The documentation for this class was generated from the following files: