ClanLib  2.3.7
List of all members
CL_Angle Class Reference

Angle class. More...

#include <angle.h>

Public Member Functions

Attributes
float to_degrees () const
 Returns the angle as degrees. More...
 
float to_radians () const
 Returns the angle as radians. More...
 
Operations
void set_degrees (float degrees)
 Set the angle value in degrees. More...
 
void set_radians (float radians)
 Set the angle value in radians. More...
 
CL_Anglenormalize ()
 Converts angle to range [0,360] degrees. More...
 
CL_Anglenormalize_180 ()
 Converts angle to range [-180,180] degrees. More...
 
Operators
void operator+= (const CL_Angle &angle)
 += operator. More...
 
void operator-= (const CL_Angle &angle)
 -= operator. More...
 
void operator*= (const CL_Angle &angle)
 *= operator. More...
 
void operator/= (const CL_Angle &angle)
 /= operator. More...
 
CL_Angle operator+ (const CL_Angle &angle) const
 
  • operator.
More...
 
CL_Angle operator- (const CL_Angle &angle) const
 
  • operator.
More...
 
CL_Angle operator* (const CL_Angle &angle) const
 
  • operator.
More...
 
CL_Angle operator* (float value) const
 
  • operator.
More...
 
CL_Angle operator/ (const CL_Angle &angle) const
 / operator. More...
 
CL_Angle operator/ (float value) const
 / operator. More...
 
bool operator< (const CL_Angle &angle) const
 < operator. More...
 
bool operator<= (const CL_Angle &angle) const
 < operator. More...
 
bool operator> (const CL_Angle &angle) const
 

operator.

More...
 
bool operator>= (const CL_Angle &angle) const
 

operator.

More...
 
bool operator== (const CL_Angle &angle) const
 == operator. More...
 
bool operator!= (const CL_Angle &angle) const
 != operator. More...
 

Construction

 CL_Angle ()
 Constructs an NULL Angle object. More...
 
 CL_Angle (float value, CL_AngleUnit unit)
 Constructs an Angle object. More...
 
static CL_Angle from_radians (float value)
 From radians. More...
 
static CL_Angle from_degrees (float value)
 From degrees. More...
 

Detailed Description

Angle class.

Constructor & Destructor Documentation

CL_Angle::CL_Angle ( )

Constructs an NULL Angle object.

CL_Angle::CL_Angle ( float  value,
CL_AngleUnit  unit 
)

Constructs an Angle object.

Member Function Documentation

static CL_Angle CL_Angle::from_degrees ( float  value)
static

From degrees.

Parameters
value= value
Returns
Angle
static CL_Angle CL_Angle::from_radians ( float  value)
static

From radians.

Parameters
value= value
Returns
Angle
CL_Angle& CL_Angle::normalize ( )

Converts angle to range [0,360] degrees.

Returns
reference to this object
CL_Angle& CL_Angle::normalize_180 ( )

Converts angle to range [-180,180] degrees.

Returns
reference to this object
bool CL_Angle::operator!= ( const CL_Angle angle) const

!= operator.

CL_Angle CL_Angle::operator* ( const CL_Angle angle) const

  • operator.

CL_Angle CL_Angle::operator* ( float  value) const

  • operator.

void CL_Angle::operator*= ( const CL_Angle angle)

*= operator.

CL_Angle CL_Angle::operator+ ( const CL_Angle angle) const

  • operator.

void CL_Angle::operator+= ( const CL_Angle angle)

+= operator.

CL_Angle CL_Angle::operator- ( const CL_Angle angle) const

  • operator.

void CL_Angle::operator-= ( const CL_Angle angle)

-= operator.

CL_Angle CL_Angle::operator/ ( const CL_Angle angle) const

/ operator.

CL_Angle CL_Angle::operator/ ( float  value) const

/ operator.

void CL_Angle::operator/= ( const CL_Angle angle)

/= operator.

bool CL_Angle::operator< ( const CL_Angle angle) const

< operator.

bool CL_Angle::operator<= ( const CL_Angle angle) const

< operator.

bool CL_Angle::operator== ( const CL_Angle angle) const

== operator.

bool CL_Angle::operator> ( const CL_Angle angle) const

operator.

bool CL_Angle::operator>= ( const CL_Angle angle) const

operator.

void CL_Angle::set_degrees ( float  degrees)

Set the angle value in degrees.

void CL_Angle::set_radians ( float  radians)

Set the angle value in radians.

float CL_Angle::to_degrees ( ) const

Returns the angle as degrees.

float CL_Angle::to_radians ( ) const

Returns the angle as radians.


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