Loading...
Searching...
No Matches
juce::Quaternion< Type > Class Template Reference

## Detailed Description

template<typename Type>
class juce::Quaternion< Type >

Holds a quaternion (a 3D vector and a scalar value).

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

- juce_opengl/geometry/juce_Quaternion.h

## Public Member Functions

| Quaternion () noexcept
| Quaternion (const Quaternion &other) noexcept
| Quaternion (Vector3D< Type > vectorPart, Type scalarPart) noexcept
| Quaternion (Type x, Type y, Type z, Type w) noexcept
Quaternion & | operator= (Quaternion other) noexcept
Quaternion & | operator*= (Quaternion other) noexcept
Type | length () const noexcept
Type | normal () const noexcept
Quaternion | normalised () const noexcept
Matrix3D< Type > | getRotationMatrix () const noexcept
| Returns the matrix that will perform the rotation specified by this quaternion.

## Static Public Member Functions

static Quaternion | fromAngle (Type angle, Vector3D< Type > axis) noexcept
| Creates a quaternion from an angle and an axis.

## Public Attributes

Vector3D< Type > | vector
| The vector part of the quaternion.
Type | scalar
| The scalar part of the quaternion.

## Constructors and Destructors

## Quaternion() [1/4]

template<typename Type>

juce::Quaternion< Type >::Quaternion | ( |  | ) |

inline noexcept

Referenced by juce::Quaternion< float >::fromAngle(), and juce::Quaternion< float >::normalised().

## Quaternion() [2/4]

template<typename Type>

juce::Quaternion< Type >::Quaternion | ( | const Quaternion< Type > & | other | ) |

inline noexcept

## Quaternion() [3/4]

template<typename Type>

juce::Quaternion< Type >::Quaternion | ( | Vector3D< Type > | vectorPart,
|  | Type | scalarPart )

inline noexcept

## Quaternion() [4/4]

template<typename Type>

juce::Quaternion< Type >::Quaternion | ( | Type | x,
|  | Type | y,
|  | Type | z,
|  | Type | w )

inline noexcept

## Member Functions

## fromAngle()

template<typename Type>

Quaternion juce::Quaternion< Type >::fromAngle | ( | Type | angle,
|  | Vector3D< Type > | axis )

inline static noexcept

Creates a quaternion from an angle and an axis.

## operator=()

template<typename Type>

Quaternion & juce::Quaternion< Type >::operator= | ( | Quaternion< Type > | other | ) |

inline noexcept

## operator*=()

template<typename Type>

Quaternion & juce::Quaternion< Type >::operator*= | ( | Quaternion< Type > | other | ) |

inline noexcept

## length()

template<typename Type>

Type juce::Quaternion< Type >::length | ( |  | ) | const

inline noexcept

Referenced by juce::Quaternion< float >::normalised().

## normal()

template<typename Type>

Type juce::Quaternion< Type >::normal | ( |  | ) | const

inline noexcept

Referenced by juce::Quaternion< float >::getRotationMatrix(), and juce::Quaternion< float >::length().

## normalised()

template<typename Type>

Quaternion juce::Quaternion< Type >::normalised | ( |  | ) | const

inline noexcept

## getRotationMatrix()

template<typename Type>

Matrix3D< Type > juce::Quaternion< Type >::getRotationMatrix | ( |  | ) | const

inline noexcept

Returns the matrix that will perform the rotation specified by this quaternion.

## Member Data Documentation

## vector

template<typename Type>

Vector3D<Type> juce::Quaternion< Type >::vector

The vector part of the quaternion.

## scalar

template<typename Type>

Type juce::Quaternion< Type >::scalar

The scalar part of the quaternion.

### Purchase

Get JUCE

### Discover

What's New in JUCE Features

### Learn

Documentaion Tutorials Made with JUCE Resources

### Support

JUCE Forum Newsletter Archive

### About

Contact Us JUCE Legal JUCE Licensing FAQ

### Events

Audio Developer Conference
© Raw Material Software Limited