hoa_video::CoordSys Class Reference

Determines the drawing coordinates. More...

#include <coord_sys.h>

Collaboration diagram for hoa_video::CoordSys:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 CoordSys (float left, float right, float bottom, float top)
 CoordSys ()
float GetBottom () const
float GetHorizontalDirection () const
float GetLeft () const
float GetRight () const
float GetTop () const
float GetVerticalDirection () const
 Class member access functions.

Private Attributes

float _bottom
float _horizontal_direction
 If the y-coordinates increase from left to right, this is 1.0f. Otherwise it is -1.0f.
float _left
 The values of the four sides of the screen that determine the drawing coordinates.
float _right
float _top
float _vertical_direction
 If the y-coordinates increase from bottom to top, this is 1.0f. Otherwise it is -1.0f.

Detailed Description

Determines the drawing coordinates.

****************************************************************************

The CoordSys structure holds a "coordinate system" defined by a rectangle (left, right, bottom, and top) which determines how drawing coordinates are mapped to the screen.

Note:
The default coordinate system is (0, 1024, 0, 768), which is the same as the game's default 1024x768 resolution.

Definition at line 34 of file coord_sys.h.


Constructor & Destructor Documentation

hoa_video::CoordSys::CoordSys (  )  [inline]

Definition at line 36 of file coord_sys.h.

hoa_video::CoordSys::CoordSys ( float  left,
float  right,
float  bottom,
float  top 
) [inline]

Definition at line 39 of file coord_sys.h.

References _bottom, _horizontal_direction, _left, _right, _top, and _vertical_direction.


Member Function Documentation

float hoa_video::CoordSys::GetBottom (  )  const [inline]

Definition at line 60 of file coord_sys.h.

References _bottom.

Referenced by hoa_video::GameVideo::_DrawStillImage(), hoa_video::TextBox::_DrawTextLines(), hoa_video::GameVideo::_ScreenCoordY(), hoa_video::GameVideo::ApplyLightingOverlay(), hoa_video::GameVideo::DrawGrid(), hoa_video::GameVideo::GetPixelSize(), and hoa_video::GameVideo::SetCoordSys().

float hoa_video::CoordSys::GetHorizontalDirection (  )  const [inline]

Definition at line 51 of file coord_sys.h.

References _horizontal_direction.

Referenced by hoa_video::GameVideo::_DrawStillImage(), hoa_video::GameVideo::_DrawTextHelper(), hoa_video::TextBox::_DrawTextLines(), hoa_video::private_video::GUIElement::CalculateAlignedRect(), hoa_video::GameVideo::Draw(), hoa_video::OptionBox::Draw(), hoa_video::GameVideo::DrawText(), and hoa_video::GameVideo::RenderText().

float hoa_video::CoordSys::GetLeft (  )  const [inline]

Definition at line 54 of file coord_sys.h.

References _left.

Referenced by hoa_video::GameVideo::_DrawStillImage(), hoa_video::TextBox::_DrawTextLines(), hoa_video::GameVideo::_ScreenCoordX(), hoa_video::GameVideo::ApplyLightingOverlay(), hoa_video::GameVideo::DrawGrid(), hoa_video::GameVideo::GetPixelSize(), and hoa_video::GameVideo::SetCoordSys().

float hoa_video::CoordSys::GetRight (  )  const [inline]

Definition at line 57 of file coord_sys.h.

References _right.

Referenced by hoa_video::GameVideo::_DrawStillImage(), hoa_video::GameVideo::_ScreenCoordX(), hoa_video::GameVideo::ApplyLightingOverlay(), hoa_video::GameVideo::DrawGrid(), hoa_video::GameVideo::GetPixelSize(), and hoa_video::GameVideo::SetCoordSys().

float hoa_video::CoordSys::GetTop (  )  const [inline]

Definition at line 63 of file coord_sys.h.

References _top.

Referenced by hoa_video::GameVideo::_DEBUG_ShowTexSheet(), hoa_video::GameVideo::_DrawStillImage(), hoa_video::GameVideo::_ScreenCoordY(), hoa_video::GameVideo::ApplyLightingOverlay(), hoa_video::GameVideo::DrawGrid(), hoa_video::GameVideo::GetPixelSize(), and hoa_video::GameVideo::SetCoordSys().

float hoa_video::CoordSys::GetVerticalDirection (  )  const [inline]

Class member access functions.

Definition at line 48 of file coord_sys.h.

References _vertical_direction.

Referenced by hoa_video::GameVideo::_DrawStillImage(), hoa_video::GameVideo::_DrawTextHelper(), hoa_video::TextBox::_DrawTextLines(), hoa_video::private_video::GUIElement::CalculateAlignedRect(), hoa_video::TextBox::Draw(), hoa_video::GameVideo::Draw(), hoa_video::OptionBox::Draw(), hoa_video::GameVideo::DrawText(), and hoa_video::GameVideo::RenderText().


Member Data Documentation

float hoa_video::CoordSys::_bottom [private]

Definition at line 75 of file coord_sys.h.

Referenced by CoordSys(), and GetBottom().

float hoa_video::CoordSys::_horizontal_direction [private]

If the y-coordinates increase from left to right, this is 1.0f. Otherwise it is -1.0f.

Definition at line 72 of file coord_sys.h.

Referenced by CoordSys(), and GetHorizontalDirection().

float hoa_video::CoordSys::_left [private]

The values of the four sides of the screen that determine the drawing coordinates.

Definition at line 75 of file coord_sys.h.

Referenced by CoordSys(), and GetLeft().

float hoa_video::CoordSys::_right [private]

Definition at line 75 of file coord_sys.h.

Referenced by CoordSys(), and GetRight().

float hoa_video::CoordSys::_top [private]

Definition at line 75 of file coord_sys.h.

Referenced by CoordSys(), and GetTop().

float hoa_video::CoordSys::_vertical_direction [private]

If the y-coordinates increase from bottom to top, this is 1.0f. Otherwise it is -1.0f.

Definition at line 69 of file coord_sys.h.

Referenced by CoordSys(), and GetVerticalDirection().


The documentation for this class was generated from the following file:
Generated on Fri Jul 6 23:16:14 2007 for Hero of Allacrost by  doxygen 1.5.1