eng::View Class Reference

View class (data struct). More...

#include <eng_view.hh>

Inheritance diagram for eng::View:

mod_sim::game::Game::MultiView

List of all members.

Public Types

enum  { MAIN_VIEW_NUM = 0 }

Public Member Functions

 View (const Rect< int > &rect, const uint dim=3, bool enable=true)
virtual ~View ()
void Enable (bool enable=true)
bool IfEnabled (void)
bool If3D (void)
uint GetFPS (void)
void SetRect (const Rect< int > &rect)
Rect< int > GetRect (void)
virtual void Reshape (const Rect< int > &mainViewRect)
SharedPtr< const MatrixGetMatrix (void)
void SetMatrix (const Matrix &matrix)
void Translate (uint axis, fp inc)
void Translate (const Vector3 &v)
void Rotate (uint axis, Radian rad)
void SetPosition (const WorldVertex &pos)
WorldVertex GetPosition (void)
Degree GetRollDeg (void)
void SetRollDeg (Degree rollDeg)

Public Attributes

CLASS_CONST uint INVALID_FRAME_CNT = 0

Private Attributes

Rect< int > mRect
 will change by reshape event
const uint mDim
 dimensions (2 or 3)
bool mEnable
Eye mEye
Degree mRollDeg
 supports Sprites

Friends

class Engine

Classes

class  Eye
 Eye. More...


Detailed Description

View class (data struct).

View class is a data struct (ie, it doesn't affect the gfxsys). View defines the area of 2D viewport and 3D viewpoint.

Adding a new View: Create a View-derivative that Overrides View::Reshape() that computes a rectangle relative to the main window. View are rendered in order of their "view num" (arg for Engine::AddView()).


Member Enumeration Documentation

anonymous enum

Enumerator:
MAIN_VIEW_NUM 


Constructor & Destructor Documentation

eng::View::View ( const Rect< int > &  rect,
const uint  dim = 3,
bool  enable = true 
)

eng::View::~View (  )  [virtual]


Member Function Documentation

void eng::View::Enable ( bool  enable = true  )  [inline]

bool eng::View::IfEnabled ( void   )  [inline]

bool eng::View::If3D ( void   )  [inline]

uint eng::View::GetFPS ( void   ) 

Returns:
FPS.

void eng::View::SetRect ( const Rect< int > &  rect  )  [inline]

Rect<int> eng::View::GetRect ( void   )  [inline]

virtual void eng::View::Reshape ( const Rect< int > &  mainViewRect  )  [inline, virtual]

Reimplemented in mod_sim::game::Game::MultiView.

SharedPtr< const Matrix > eng::View::GetMatrix ( void   ) 

Eye pass-thru methods.

void eng::View::SetMatrix ( const Matrix &  matrix  ) 

void eng::View::Translate ( uint  axis,
fp  inc 
)

void eng::View::Translate ( const Vector3 &  v  ) 

void eng::View::Rotate ( uint  axis,
Radian  rad 
)

void eng::View::SetPosition ( const WorldVertex &  pos  ) 

WorldVertex eng::View::GetPosition ( void   ) 

Degree eng::View::GetRollDeg ( void   ) 

Support for Sprites.

void eng::View::SetRollDeg ( Degree  rollDeg  ) 


Friends And Related Function Documentation

friend class Engine [friend]


Member Data Documentation

CLASS_CONST uint eng::View::INVALID_FRAME_CNT = 0

Rect<int> eng::View::mRect [private]

will change by reshape event

const uint eng::View::mDim [private]

dimensions (2 or 3)

bool eng::View::mEnable [private]

Eye eng::View::mEye [private]

Degree eng::View::mRollDeg [private]

supports Sprites


The documentation for this class was generated from the following files: Palomino 3D Engine documents generated by doxygen 1.5.3 on Fri Nov 23 11:26:25 2007