#include <Spline.h>
|
| | SplineBase () |
| |
| | SplineBase (SplineBase const &right)=delete |
| |
| | SplineBase (SplineBase &&right)=delete |
| |
| SplineBase & | operator= (SplineBase const &right)=delete |
| |
| SplineBase & | operator= (SplineBase &&right)=delete |
| |
| virtual | ~SplineBase () |
| |
| void | evaluate_percent (index_type Idx, float u, Vector3 &c) const |
| |
| void | evaluate_derivative (index_type Idx, float u, Vector3 &hermite) const |
| |
| index_type | first () const |
| |
| index_type | last () const |
| |
| bool | empty () const |
| |
| EvaluationMode | mode () const |
| |
| bool | isCyclic () const |
| |
| ControlArray const & | getPoints () const |
| |
| index_type | getPointCount () const |
| |
| Vector3 const & | getPoint (index_type i) const |
| |
| void | init_spline (const Vector3 *controls, index_type count, EvaluationMode m, float orientation=0.0f) |
| |
| void | init_cyclic_spline (const Vector3 *controls, index_type count, EvaluationMode m, index_type cyclic_point, float orientation=0.0f) |
| |
| template<class Init > |
| void | init_spline_custom (Init &&initializer) |
| |
| virtual void | clear () |
| |
| float | SegLength (index_type i) const |
| |
| void | set_steps_per_segment (index_type newStepsPerSegment) |
| |
| std::string | ToString () const |
| |
|
| void | EvaluateLinear (index_type, float, Vector3 &) const |
| |
| void | EvaluateCatmullRom (index_type, float, Vector3 &) const |
| |
| void | EvaluateBezier3 (index_type, float, Vector3 &) const |
| |
| void | EvaluateDerivativeLinear (index_type, float, Vector3 &) const |
| |
| void | EvaluateDerivativeCatmullRom (index_type, float, Vector3 &) const |
| |
| void | EvaluateDerivativeBezier3 (index_type, float, Vector3 &) const |
| |
| float | SegLengthLinear (index_type) const |
| |
| float | SegLengthCatmullRom (index_type) const |
| |
| float | SegLengthBezier3 (index_type) const |
| |
| void | InitLinear (Vector3 const *, index_type, index_type) |
| |
| void | InitCatmullRom (Vector3 const *, index_type, index_type) |
| |
| void | InitBezier3 (Vector3 const *, index_type, index_type) |
| |
| void | UninitializedSplineEvaluationMethod (index_type, float, Vector3 &) const |
| |
| float | UninitializedSplineSegLenghtMethod (index_type) const |
| |
| void | UninitializedSplineInitMethod (Vector3 const *, index_type, index_type) |
| |
Definition at line 29 of file Spline.h.
◆ ControlArray
◆ EvaluationMethtod
| typedef void(SplineBase::* Movement::SplineBase::EvaluationMethtod) (index_type, float, Vector3 &) const |
|
protected |
◆ index_type
◆ InitMethtod
| typedef void(SplineBase::* Movement::SplineBase::InitMethtod) (Vector3 const *, index_type, index_type) |
|
protected |
◆ SegLenghtMethtod
| typedef float(SplineBase::* Movement::SplineBase::SegLenghtMethtod) (index_type) const |
|
protected |
◆ EvaluationMode
| Enumerator |
|---|
| ModeLinear | |
| ModeCatmullrom | |
| ModeBezier3_Unused | |
| UninitializedMode | |
| ModesEnd | |
Definition at line 35 of file Spline.h.
◆ SplineBase() [1/3]
| Movement::SplineBase::SplineBase |
( |
| ) |
|
|
explicit |
◆ SplineBase() [2/3]
| Movement::SplineBase::SplineBase |
( |
SplineBase const & |
right | ) |
|
|
delete |
◆ SplineBase() [3/3]
| Movement::SplineBase::SplineBase |
( |
SplineBase && |
right | ) |
|
|
delete |
◆ ~SplineBase()
| Movement::SplineBase::~SplineBase |
( |
| ) |
|
|
virtualdefault |
◆ clear()
| void Movement::SplineBase::clear |
( |
| ) |
|
|
virtual |
◆ empty()
| bool Movement::SplineBase::empty |
( |
| ) |
const |
|
inline |
◆ evaluate_derivative()
| void Movement::SplineBase::evaluate_derivative |
( |
index_type |
Idx, |
|
|
float |
u, |
|
|
Vector3 & |
hermite |
|
) |
| const |
|
inline |
Caclulates derivation in index Idx, and percent of segment length t
- Parameters
-
| Idx | - spline segment index, should be in range [first, last) |
| t | - percent of spline segment length, assumes that t in range [0, 1] |
Definition at line 107 of file Spline.h.
◆ evaluate_percent()
| void Movement::SplineBase::evaluate_percent |
( |
index_type |
Idx, |
|
|
float |
u, |
|
|
Vector3 & |
c |
|
) |
| const |
|
inline |
Caclulates the position for given segment Idx, and percent of segment length t
- Parameters
-
| t | - percent of segment length, assumes that t in range [0, 1] |
| Idx | - spline segment index, should be in range [first, last) |
Definition at line 101 of file Spline.h.
◆ EvaluateBezier3()
| void Movement::SplineBase::EvaluateBezier3 |
( |
index_type |
index, |
|
|
float |
t, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ EvaluateCatmullRom()
| void Movement::SplineBase::EvaluateCatmullRom |
( |
index_type |
index, |
|
|
float |
t, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ EvaluateDerivativeBezier3()
| void Movement::SplineBase::EvaluateDerivativeBezier3 |
( |
index_type |
index, |
|
|
float |
t, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ EvaluateDerivativeCatmullRom()
| void Movement::SplineBase::EvaluateDerivativeCatmullRom |
( |
index_type |
index, |
|
|
float |
t, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ EvaluateDerivativeLinear()
| void Movement::SplineBase::EvaluateDerivativeLinear |
( |
index_type |
index, |
|
|
float |
, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ EvaluateLinear()
| void Movement::SplineBase::EvaluateLinear |
( |
index_type |
index, |
|
|
float |
u, |
|
|
Vector3 & |
result |
|
) |
| const |
|
protected |
◆ first()
Bounds for spline indexes. All indexes should be in range [first, last).
Definition at line 110 of file Spline.h.
◆ getPoint()
| Vector3 const & Movement::SplineBase::getPoint |
( |
index_type |
i | ) |
const |
|
inline |
◆ getPointCount()
| index_type Movement::SplineBase::getPointCount |
( |
| ) |
const |
|
inline |
◆ getPoints()
| ControlArray const & Movement::SplineBase::getPoints |
( |
| ) |
const |
|
inline |
◆ init_cyclic_spline()
◆ init_spline()
| void Movement::SplineBase::init_spline |
( |
const Vector3 * |
controls, |
|
|
index_type |
count, |
|
|
EvaluationMode |
m, |
|
|
float |
orientation = 0.0f |
|
) |
| |
Initializes spline. Don't call other methods while spline not initialized.
Definition at line 201 of file Spline.cpp.
◆ init_spline_custom()
template<class Init >
| void Movement::SplineBase::init_spline_custom |
( |
Init && |
initializer | ) |
|
|
inline |
As i can see there are a lot of ways how spline can be initialized would be no harm to have some custom initializers.
Definition at line 128 of file Spline.h.
◆ InitBezier3()
◆ InitCatmullRom()
| void Movement::SplineBase::InitCatmullRom |
( |
Vector3 const * |
controls, |
|
|
index_type |
count, |
|
|
index_type |
cyclic_point |
|
) |
| |
|
protected |
◆ InitLinear()
| void Movement::SplineBase::InitLinear |
( |
Vector3 const * |
controls, |
|
|
index_type |
count, |
|
|
index_type |
cyclic_point |
|
) |
| |
|
protected |
◆ isCyclic()
| bool Movement::SplineBase::isCyclic |
( |
| ) |
const |
|
inline |
◆ last()
◆ mode()
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ SegLength()
| float Movement::SplineBase::SegLength |
( |
index_type |
i | ) |
const |
|
inline |
Calculates distance between [i; i+1] points, assumes that index i is in bounds.
Definition at line 136 of file Spline.h.
◆ SegLengthBezier3()
| float Movement::SplineBase::SegLengthBezier3 |
( |
index_type |
index | ) |
const |
|
protected |
◆ SegLengthCatmullRom()
| float Movement::SplineBase::SegLengthCatmullRom |
( |
index_type |
index | ) |
const |
|
protected |
◆ SegLengthLinear()
| float Movement::SplineBase::SegLengthLinear |
( |
index_type |
index | ) |
const |
|
protected |
◆ set_steps_per_segment()
| void Movement::SplineBase::set_steps_per_segment |
( |
index_type |
newStepsPerSegment | ) |
|
|
inline |
◆ ToString()
| std::string Movement::SplineBase::ToString |
( |
| ) |
const |
◆ UninitializedSplineEvaluationMethod()
| void Movement::SplineBase::UninitializedSplineEvaluationMethod |
( |
index_type |
, |
|
|
float |
, |
|
|
Vector3 & |
|
|
) |
| const |
|
inlineprotected |
◆ UninitializedSplineInitMethod()
| void Movement::SplineBase::UninitializedSplineInitMethod |
( |
Vector3 const * |
, |
|
|
index_type |
, |
|
|
index_type |
|
|
) |
| |
|
inlineprotected |
◆ UninitializedSplineSegLenghtMethod()
| float Movement::SplineBase::UninitializedSplineSegLenghtMethod |
( |
index_type |
| ) |
const |
|
inlineprotected |
◆ cyclic
| bool Movement::SplineBase::cyclic |
|
protected |
◆ derivative_evaluators
Initial value:=
{
}
void EvaluateDerivativeCatmullRom(index_type, float, Vector3 &) const
void EvaluateDerivativeBezier3(index_type, float, Vector3 &) const
void EvaluateDerivativeLinear(index_type, float, Vector3 &) const
void UninitializedSplineEvaluationMethod(index_type, float, Vector3 &) const
Definition at line 70 of file Spline.h.
◆ evaluators
Initial value:=
{
}
void EvaluateCatmullRom(index_type, float, Vector3 &) const
void EvaluateBezier3(index_type, float, Vector3 &) const
void EvaluateLinear(index_type, float, Vector3 &) const
Definition at line 65 of file Spline.h.
◆ index_hi
◆ index_lo
◆ initializers
Initial value:=
{
}
void UninitializedSplineInitMethod(Vector3 const *, index_type, index_type)
void InitBezier3(Vector3 const *, index_type, index_type)
void InitCatmullRom(Vector3 const *, index_type, index_type)
Definition at line 82 of file Spline.h.
◆ initialOrientation
| float Movement::SplineBase::initialOrientation |
|
protected |
◆ m_mode
| uint8 Movement::SplineBase::m_mode |
|
protected |
◆ points
◆ seglengths
Initial value:=
{
}
float SegLengthLinear(index_type) const
float SegLengthBezier3(index_type) const
float UninitializedSplineSegLenghtMethod(index_type) const
float SegLengthCatmullRom(index_type) const
Definition at line 76 of file Spline.h.
◆ stepsPerSegment
| index_type Movement::SplineBase::stepsPerSegment = 3 |
|
protected |
The documentation for this class was generated from the following files: