Flair
Framework Libre Air
|
Class defining a 3D vector and a io_data User must manually use the io_data's Mutex to access to Vector3D values. More...
#include <Vector3Ddata.h>
Public Member Functions | |
Vector3Ddata (const Object *parent, std::string name, float x=0, float y=0, float z=0, uint32_t n=1) | |
Constructor. More... | |
~Vector3Ddata () | |
Destructor. More... | |
IODataElement * | XElement (void) const |
X Element. More... | |
IODataElement * | YElement (void) const |
Y Element. More... | |
IODataElement * | ZElement (void) const |
Z Element. More... | |
Public Member Functions inherited from flair::core::io_data | |
io_data (const Object *parent, std::string name, int n) | |
Constructor. More... | |
virtual | ~io_data () |
Destructor. More... | |
void | SetDataTime (Time time) |
Set data time, also caluculates the delta time based on last call. More... | |
void | SetDataTime (Time time, Time deltaTime) |
Set data time and delta time (thus delta time is not based on last call) More... | |
Time | DataTime (void) const |
Data time. More... | |
Time | DataDeltaTime (void) const |
Data delta time. More... | |
void | GetDataTime (Time &time, Time &deltaTime) const |
Get data time and delta time. More... | |
const io_data * | Prev (int n) const |
Previous data. More... | |
virtual DataType const & | GetDataType () const =0 |
virtual void | RawWrite (char *src) |
Raw write datas. More... | |
virtual void | RawRead (char *dst) const =0 |
Raw read datas. More... | |
Public Member Functions inherited from flair::core::Mutex | |
Mutex (const Object *parent, std::string name="") | |
Constructor. More... | |
~Mutex () | |
Destructor. More... | |
void | GetMutex (void) const |
GetMutex. More... | |
void | ReleaseMutex (void) const |
ReleaseMutex. More... | |
Public Member Functions inherited from flair::core::Object | |
Object (const Object *parent=NULL, std::string name="", std::string type="") | |
Constructor. More... | |
virtual | ~Object () |
Destructor. More... | |
std::string | ObjectName (void) const |
Name. More... | |
std::string | ObjectType (void) const |
Type. More... | |
const Object * | Parent (void) const |
Parent. More... | |
std::vector< const Object * > * | TypeChilds (void) const |
Childs of the same type. More... | |
std::vector< const Object * > * | Childs (void) const |
Childs. More... | |
void | Information (const char *function, int line, const char *format,...) const |
Formatted information. More... | |
void | Warning (const char *function, const char *format,...) const |
Formatted warning. More... | |
void | Error (const char *function, const char *format,...) const |
Formatted error. More... | |
bool | ErrorOccured (bool recursive=true) const |
Has an errror occured? More... | |
Public Member Functions inherited from flair::core::Vector3D< T > | |
Vector3D (T x=0, T y=0, T z=0) | |
Constructor. More... | |
~Vector3D () | |
Destructor. More... | |
void | RotateX (float value) |
x axis rotation More... | |
void | RotateXDeg (float value) |
x axis rotation More... | |
void | RotateY (float value) |
y axis rotation More... | |
void | RotateYDeg (float value) |
y axis rotation More... | |
void | RotateZ (float value) |
z axis rotation More... | |
void | RotateZDeg (float value) |
z axis rotation More... | |
void | Rotate (const RotationMatrix &matrix) |
rotation More... | |
void | Rotate (const Quaternion &quaternion) |
rotation More... | |
void | To2Dxy (Vector2D< T > &vector) const |
Convert to a Vector2D. More... | |
Vector2D< T > | To2Dxy (void) const |
Convert to a Vector2D. More... | |
float | GetNorm (void) const |
Norm. More... | |
void | Normalize (void) |
Normalize. More... | |
void | Saturate (const Vector3D< T > &min, const Vector3D< T > &max) |
Saturate. More... | |
void | Saturate (float min, float max) |
Saturate. More... | |
void | Saturate (const Vector3D< T > &value) |
Saturate. More... | |
void | Saturate (float value) |
Saturate. More... | |
T & | operator[] (size_t idx) |
const T & | operator[] (size_t idx) const |
template<typename S > | |
Vector3D< T > & | operator= (const Vector3D< S > &vector) |
Vector3D< T > & | operator+= (const Vector3D< T > &vector) |
Vector3D< T > & | operator-= (const Vector3D< T > &vector) |
Additional Inherited Members | |
Public Types inherited from flair::core::Object | |
enum | color_t { Auto = 0, Red = 31, Green = 32, Orange = 33 } |
Public Attributes inherited from flair::core::Vector3D< T > | |
T | x |
x More... | |
T | y |
y More... | |
T | z |
z More... | |
Protected Member Functions inherited from flair::core::io_data | |
void | AppendLogDescription (std::string description, DataType const &datatype) |
Specify the description of the reimplemented class data's. More... | |
void | SetPtrToCircle (void **ptr) |
Set the datas to circle. More... | |
Protected Attributes inherited from flair::core::io_data | |
io_data * | prev |
Pointer to previous data. More... | |
Class defining a 3D vector and a io_data User must manually use the io_data's Mutex to access to Vector3D values.
flair::core::Vector3Ddata::Vector3Ddata | ( | const Object * | parent, |
std::string | name, | ||
float | x = 0 , |
||
float | y = 0 , |
||
float | z = 0 , |
||
uint32_t | n = 1 |
||
) |
flair::core::Vector3Ddata::~Vector3Ddata | ( | ) |
Destructor.
IODataElement* flair::core::Vector3Ddata::XElement | ( | void | ) | const |
X Element.
Get a vectorer to x element. This pointer can be used for plotting.
IODataElement* flair::core::Vector3Ddata::YElement | ( | void | ) | const |
Y Element.
Get a pointer to y element. This pointer can be used for plotting.
IODataElement* flair::core::Vector3Ddata::ZElement | ( | void | ) | const |
Z Element.
Get a pointer to z element. This pointer can be used for plotting.