template<class T>
Magnum::SceneGraph::AbstractBasicTranslationRotation3D class

Base transformation for three-dimensional scenes supporting translation and rotation.

See Polymorphic access to object transformation for more information.

Base classes

template<UnsignedInt dimensions, class T, class TranslationType = T>
class AbstractTranslation
Base transformation for two-dimensional scenes supporting translation.

Derived classes

template<class T>
class AbstractBasicTranslationRotationScaling3D
Base transformation for three-dimensional scenes supporting translation, rotation and scaling.
template<class T>
class BasicDualQuaternionTransformation
Three-dimensional transformation implemented using dual quaternions.
template<class T>
class BasicRigidMatrixTransformation3D
Three-dimensional rigid transformation implemented using matrices.

Public functions

auto rotate(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis) -> AbstractBasicTranslationRotation3D<T>&
Rotate object.
auto rotateLocal(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis) -> AbstractBasicTranslationRotation3D<T>&
Rotate object as a local transformation.
auto rotateX(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around X axis.
auto rotateXLocal(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around X axis as a local transformation.
auto rotateY(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around Y axis.
auto rotateYLocal(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around Y axis as a local transformation.
auto rotateZ(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around Z axis.
auto rotateZLocal(Math::Rad<T> angle) -> AbstractBasicTranslationRotation3D<T>&
Rotate object around Z axis as a local transformation.

Protected functions

void doRotate(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis) pure virtual
Polymorphic implementation for rotate()
void doRotateLocal(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis) pure virtual
Polymorphic implementation for rotateLocal()
void doRotateX(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateX()
void doRotateXLocal(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateXLocal()
void doRotateY(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateY()
void doRotateYLocal(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateYLocal()
void doRotateZ(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateZ()
void doRotateZLocal(Math::Rad<T> angle) virtual
Polymorphic implementation for rotateZLocal()

Function documentation

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotate(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis)

Rotate object.

Parameters
angle Angle (counterclockwise)
normalizedAxis Normalized rotation axis
Returns Reference to self (for method chaining)

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateLocal(Math::Rad<T> angle, const Math::Vector3<T>& normalizedAxis)

Rotate object as a local transformation.

Similar to the above, except that the transformation is applied before all others.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateX(Math::Rad<T> angle)

Rotate object around X axis.

Parameters
angle Angle (counterclockwise)
Returns Reference to self (for method chaining)

In some implementations faster than calling rotate(angle, Vector3::xAxis()), see subclasses for more information.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateXLocal(Math::Rad<T> angle)

Rotate object around X axis as a local transformation.

Similar to the above, except that the transformation is applied before all others. In some implementations faster than calling rotateLocal(angle, Vector3::xAxis()), see subclasses for more information.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateY(Math::Rad<T> angle)

Rotate object around Y axis.

Parameters
angle Angle (counterclockwise)
Returns Reference to self (for method chaining)

In some implementations faster than calling rotate(angle, Vector3::yAxis()), see subclasses for more information.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateYLocal(Math::Rad<T> angle)

Rotate object around Y axis as a local transformation.

Similar to the above, except that the transformation is applied before all others. In some implementations faster than calling rotateLocal(angle, Vector3::yAxis()), see subclasses for more information.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateZ(Math::Rad<T> angle)

Rotate object around Z axis.

Parameters
angle Angle (counterclockwise)
Returns Reference to self (for method chaining)

In some implementations faster than calling rotate(angle, Vector3::zAxis()), see subclasses for more information.

template<class T>
AbstractBasicTranslationRotation3D<T>& Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::rotateZLocal(Math::Rad<T> angle)

Rotate object around Z axis as a local transformation.

Similar to the above, except that the transformation is applied before all others. In some implementations faster than calling rotateLocal(angle, Vector3::zAxis()), see subclasses for more information.

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateX(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateX()

Default implementation calls rotate() with Math::Vector3::xAxis().

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateXLocal(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateXLocal()

Default implementation calls rotateLocal() with Math::Vector3::xAxis().

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateY(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateY()

Default implementation calls rotate() with Math::Vector3::yAxis().

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateYLocal(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateYLocal()

Default implementation calls rotateLocal() with Math::Vector3::yAxis().

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateZ(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateZ()

Default implementation calls rotate() with Math::Vector3::zAxis().

template<class T>
void Magnum::SceneGraph::AbstractBasicTranslationRotation3D<T>::doRotateZLocal(Math::Rad<T> angle) virtual protected

Polymorphic implementation for rotateZLocal()

Default implementation calls rotateLocal() with Math::Vector3::zAxis().