Hummingbird Framework
 All Classes Functions Variables Modules Pages
hb::Transform Class Reference

Object with a position, rotation and scale in a 3D space. More...

#include <Transform.h>

Inheritance diagram for hb::Transform:

Public Member Functions

 Transform ()
 Default constructor. More...
 
 Transform (const Vector3d &init_pos)
 Constructor with initial position.
 
 ~Transform ()
 Class destructor.
 
const Vector3dgetPosition () const
 Get Transform position. More...
 
void setPosition (const Vector3d &p)
 Set position from a Vector3d. More...
 
void setPosition (double p_x, double p_y, double p_z)
 Set position from doubles. More...
 
const Vector3dgetRotation () const
 Get Transform rotation. More...
 
void setRotation (const Vector3d &rotation)
 Set rotation from a Vector3d. More...
 
void setRotation (double rotation_x, double rotation_y, double rotation_z)
 Set rotation from doubles. More...
 
const Vector3dgetScale () const
 Get Transform scale. More...
 
void setScale (const Vector3d &scale)
 Set scale from a Vector3d. More...
 
void setScale (double scale_x, double scale_y, double scale_z)
 Set position from doubles. More...
 

Detailed Description

Object with a position, rotation and scale in a 3D space.

Constructor & Destructor Documentation

hb::Transform::Transform ( )

Default constructor.

All values to 0.

Member Function Documentation

const Vector3d& hb::Transform::getPosition ( ) const

Get Transform position.

Returns
Transform position.
const Vector3d& hb::Transform::getRotation ( ) const

Get Transform rotation.

Returns
Transform rotation.
const Vector3d& hb::Transform::getScale ( ) const

Get Transform scale.

Returns
Transform scale.
void hb::Transform::setPosition ( const Vector3d p)

Set position from a Vector3d.

Parameters
pNew position
void hb::Transform::setPosition ( double  p_x,
double  p_y,
double  p_z 
)

Set position from doubles.

Parameters
p_xNew x position.
p_yNew y position.
p_zNew z position.
void hb::Transform::setRotation ( const Vector3d rotation)

Set rotation from a Vector3d.

Parameters
rotationNew rotation
void hb::Transform::setRotation ( double  rotation_x,
double  rotation_y,
double  rotation_z 
)

Set rotation from doubles.

Parameters
rotation_xNew rotation around the X axis.
rotation_yNew rotation around the Y axis.
rotation_zNew rotation around the Z axis.
void hb::Transform::setScale ( const Vector3d scale)

Set scale from a Vector3d.

Parameters
scaleNew scale
void hb::Transform::setScale ( double  scale_x,
double  scale_y,
double  scale_z 
)

Set position from doubles.

Parameters
scale_xNew scale over the X axis.
scale_yNew scale over the Y axis.
scale_zNew scale over the Z axis.

The documentation for this class was generated from the following file: