pixled-lib  1.0
Public Member Functions | Static Public Member Functions | List of all members
pixled::angle Class Reference

#include <geometry.h>

Public Member Functions

float toRad () const
 
float toDeg () const
 
angleoperator+= (const angle &a)
 
angleoperator-= (const angle &a)
 

Static Public Member Functions

static angle fromRad (float value)
 
static angle fromDeg (float value)
 

Detailed Description

Basic class used to represent angles, with radian / degree conversion.

Member Function Documentation

◆ fromRad()

angle pixled::angle::fromRad ( float  value)
static

Builds an angle from the specified value, in radian.

Parameters
valuevalue of the angle in radian

◆ fromDeg()

angle pixled::angle::fromDeg ( float  value)
static

Builds an angle from the specified value, in degree.

Parameters
valuevalue of the angle in degree

◆ toRad()

float pixled::angle::toRad ( ) const
inline

Returns the value of this angle, in radian.

Returns
value in radian

◆ toDeg()

float pixled::angle::toDeg ( ) const
inline

Returns the value of this angle, in degree.

Returns
value in degree

◆ operator+=()

angle& pixled::angle::operator+= ( const angle a)
inline

Adds a to this angle.

Parameters
aangle to add
Returns
reference to this angle

◆ operator-=()

angle& pixled::angle::operator-= ( const angle a)
inline

Substracts a from this angle.

Parameters
aangle to substract
Returns
reference to this angle

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