Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

Angle Class Reference
[Fixed-Point math routines]

Class used to handle fixed-point angles. More...

#include <Fxp.h>

List of all members.

Public Member Functions

 Angle (Afxp ain)
 Initializes from a raw fixed-point angle.

 Angle (int degrees)
 Initializes from an integer number of degrees.

 Angle (FxpFloat radians)
 Initializes from a floating-point radian value.

int Degrees () const
 Converts to an integer number of degrees.

FxpFloat Radians () const
 Converts to a floating-point radian value.

Afxp Fxp () const
 Returns the raw floating-point angle.

Angle operator+= (Afxp ain)
 Adds specified angle to the stored angle.

Angle operator-= (Afxp ain)
 Subtracts specified angle from the stored angle.

Angle operator+ (const Angle &ain)
 Returns the sum of the two angles.

Angle SetDegrees (int degrees)
 Sets to an integer number of degrees.

Angle SetRadians (double radians)
 Sets to a floating-point radian value.

Sfxp Sin () const
 Returns the sine value for the angle.

Sfxp Cos () const
 Returns the cosine value for the angle.

Sfxp Tan () const
 Returns the tan value for the angle.


Detailed Description

This is also a simple class that does a lot of things. It can convert to/from radian, degree, and fixed-point angles, return calculated trigonometric values, increment, decrement, and more. Lots of things you can do with angles.

Definition at line 302 of file Fxp.h.


The documentation for this class was generated from the following file:
Generated on Sat Oct 11 13:19:34 2003 for Spritelib by doxygen 1.3.4