|
PGR Copakond OpenGL Engine - Bowling
|
Base class for parameterized spline animations. More...
#include <spline.h>
Public Member Functions | |
| virtual | ~Spline ()=default |
| Spline (float duration, std::vector< glm::vec3 > &points, glm::vec3 &vector) | |
| Spline (float duration, std::vector< glm::vec3 > &points, std::function< void(glm::vec3)> applyVector) | |
| Spline (float duration, std::vector< glm::vec3 > &points, glm::vec3 &vector, glm::vec3 &vectorDerivative) | |
| Spline (float duration, std::vector< glm::vec3 > &points, std::function< void(glm::vec3)> applyVector, glm::vec3 &vectorDerivative) | |
| Spline (float duration, std::vector< glm::vec3 > &points, glm::vec3 &vector, std::function< void(glm::vec3)> applyVectorDerivative) | |
| Spline (float duration, std::vector< glm::vec3 > &points, std::function< void(glm::vec3)> applyVector, std::function< void(glm::vec3)> applyVectorDerivative) | |
| void | update (float deltaTime) |
| Updates spline state and calculates new vectors based on time. | |
| void | pause () |
| void | unpause () |
| void | reset () |
Protected Member Functions | |
| virtual glm::vec3 | evaluateNormal (float localT)=0 |
| virtual glm::vec3 | evaluateDerivative (float localT)=0 |
Protected Attributes | |
| float | t = 0.0f |
| float | duration |
| size_t | pointsCount |
| bool | hasDerivative |
| bool | paused = false |
| bool | hasFunctionVector = false |
| bool | hasFunctionVectorDerivative = false |
| std::function< void(glm::vec3)> | applyVector |
| std::function< void(glm::vec3)> | applyVectorDerivative |
| std::vector< glm::vec3 > | points |
| glm::vec3 & | vector |
| glm::vec3 & | vectorDerivative |
| glm::vec3 | _P0 |
| glm::vec3 | _P1 |
| glm::vec3 | _P2 |
| glm::vec3 | _P3 |
Base class for parameterized spline animations.
|
virtualdefault |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| glm::vec3 & | vector ) |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| std::function< void(glm::vec3)> | applyVector ) |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| glm::vec3 & | vector, | ||
| glm::vec3 & | vectorDerivative ) |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| std::function< void(glm::vec3)> | applyVector, | ||
| glm::vec3 & | vectorDerivative ) |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| glm::vec3 & | vector, | ||
| std::function< void(glm::vec3)> | applyVectorDerivative ) |
| copakond::Spline::Spline | ( | float | duration, |
| std::vector< glm::vec3 > & | points, | ||
| std::function< void(glm::vec3)> | applyVector, | ||
| std::function< void(glm::vec3)> | applyVectorDerivative ) |
|
protectedpure virtual |
Implemented in copakond::Bezier, and copakond::CatmullRoll.
|
protectedpure virtual |
Implemented in copakond::Bezier, and copakond::CatmullRoll.
|
inline |
|
inline |
|
inline |
| void copakond::Spline::update | ( | float | deltaTime | ) |
Updates spline state and calculates new vectors based on time.
| deltaTime | Time elapsed since the last frame. |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Callback function to apply calculated position
|
protected |
Callback function to apply calculated tangent
|
protected |
Total time to complete one full spline loop
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Number of control points
|
protected |
Current continuous time of the spline animation
|
protected |
|
protected |