Flair
Framework Libre Air
flair::core::Vector3Ddata Class Reference

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>

+ Inheritance diagram for flair::core::Vector3Ddata:

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...
 
IODataElementXElement (void) const
 X Element. More...
 
IODataElementYElement (void) const
 Y Element. More...
 
IODataElementZElement (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. More...
 
Time DataTime (void) const
 Data time. More...
 
const io_dataPrev (int n) const
 Previous data. More...
 
virtual DataType const & GetDataType () const =0
 
- 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 ObjectParent (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
 Vector3D (float x=0, float y=0, float 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 &vector) const
 Convert to a Vector2D. More...
 
Vector2D To2Dxy (void) const
 Convert to a Vector2D. More...
 
float GetNorm (void) const
 Norm. More...
 
void Normalize (void)
 Normalize. More...
 
void Saturate (const Vector3D &min, const Vector3D &max)
 Saturate. More...
 
void Saturate (float min, float max)
 Saturate. More...
 
void Saturate (const Vector3D &value)
 Saturate. More...
 
void Saturate (float value)
 Saturate. More...
 
float & operator[] (size_t idx)
 
const float & operator[] (size_t idx) const
 
Vector3Doperator= (const Vector3D &vector)
 
Vector3Doperator+= (const Vector3D &vector)
 
Vector3Doperator-= (const Vector3D &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
float x
 x More...
 
float y
 y More...
 
float 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_dataprev
 Pointer to previous data. More...
 

Detailed Description

Class defining a 3D vector and a io_data User must manually use the io_data's Mutex to access to Vector3D values.

Constructor & Destructor Documentation

flair::core::Vector3Ddata::Vector3Ddata ( const Object parent,
std::string  name,
float  x = 0,
float  y = 0,
float  z = 0,
uint32_t  n = 1 
)

Constructor.

Construct a Vector3D using specified values.

Parameters
x
y
z
flair::core::Vector3Ddata::~Vector3Ddata ( )

Destructor.

Member Function Documentation

IODataElement* flair::core::Vector3Ddata::XElement ( void  ) const

X Element.

Get a vectorer to x element. This pointer can be used for plotting.

Returns
pointer to the element
IODataElement* flair::core::Vector3Ddata::YElement ( void  ) const

Y Element.

Get a pointer to y element. This pointer can be used for plotting.

Returns
pointer to the element
IODataElement* flair::core::Vector3Ddata::ZElement ( void  ) const

Z Element.

Get a pointer to z element. This pointer can be used for plotting.

Returns
pointer to the element