orxonox::GSGraphics Class Reference

Game state used when displaying graphics of any kind. Another blubb resides here. More...

#include <src/orxonox/gamestates/GSGraphics.h>

Inheritance diagram for orxonox::GSGraphics:

orxonox::GameState orxonox::WindowEventListener orxonox::OrxonoxClass

List of all members.

Public Member Functions

void activate ()
 This function is called when we enter this game state.
void deactivate ()
 This function is called when the game state is left.
 GSGraphics (const GameStateConstrParams &params)
void setConfigValues ()
 this function does nothing
void toggleGUI ()
 Toggles the visibility of the current GUI.
void update (const Clock &time)
 ~GSGraphics ()

Private Member Functions

void windowFocusChanged ()
 Window focus has changed.
void windowResized (unsigned int newWidth, unsigned int newHeight)
 Window has resized.

Private Attributes

ConsoleCommandccToggleGUI_
 Console command to toggle GUI.
InGameConsoleconsole_
XMLFiledebugOverlay_
GraphicsManagergraphicsManager_
 Interface to Ogre.
GUIManagerguiManager_
 Interface to GUI.
InputManagerinputManager_
 Reference to input management.
SimpleInputStatemasterInputState_
 Special input state for master input.
KeyBindermasterKeyBinder_
 Key binder for master key bindings.
SoundManagersoundManager_
 Keeps track of SoundBase objects.


Detailed Description

Game state used when displaying graphics of any kind. Another blubb resides here.

This game state is only left out if we start a dedicated server where no graphics are present.


Constructor & Destructor Documentation

orxonox::GSGraphics::GSGraphics ( const GameStateConstrParams params  ) 

References RegisterRootObject.

orxonox::GSGraphics::~GSGraphics (  ) 


Member Function Documentation

void orxonox::GSGraphics::activate (  )  [virtual]

void orxonox::GSGraphics::deactivate (  )  [virtual]

void orxonox::GSGraphics::setConfigValues (  ) 

this function does nothing

Indeed. Here goes nothing.

Reimplemented from orxonox::OrxonoxClass.

Referenced by activate().

void orxonox::GSGraphics::toggleGUI (  ) 

Toggles the visibility of the current GUI.

This function just executes a Lua function in the main script of the GUI by accessing the GUIManager. For more details on this function check out the Lua code.

References orxonox::GUIManager::executeCode(), and orxonox::GUIManager::getInstance().

Referenced by activate().

void orxonox::GSGraphics::update ( const Clock time  )  [virtual]

Note:
A note about the Ogre::FrameListener: Even though we don't use them, they still get called. However, the delta times are not correct (except for timeSinceLastFrame, which is the most important). A little research as shown that there is probably only one FrameListener that doesn't even need the time. So we shouldn't run into problems.

Reimplemented from orxonox::GameState.

References orxonox::Game::addTickTime(), console_, orxonox::GameState::getActivity(), orxonox::Game::getInstance(), orxonox::Clock::getRealMicroseconds(), graphicsManager_, guiManager_, inputManager_, orxonox::Game::requestState(), orxonox::GraphicsManager::update(), orxonox::GUIManager::update(), orxonox::InGameConsole::update(), and orxonox::InputManager::update().

void orxonox::GSGraphics::windowFocusChanged (  )  [private, virtual]

Window focus has changed.

Parameters:
rw The render window it occured in

Reimplemented from orxonox::WindowEventListener.

References orxonox::InputManager::clearBuffers(), and inputManager_.

void orxonox::GSGraphics::windowResized ( unsigned int  newWidth,
unsigned int  newHeight 
) [private, virtual]

Window has resized.

Parameters:
rw The render window it occured in
Note:
GraphicsManager has a render window stored itself. This is the same as rw. But we have to be careful when using multiple render windows!

Reimplemented from orxonox::WindowEventListener.

References inputManager_, and orxonox::InputManager::setWindowExtents().


Member Data Documentation

Console command to toggle GUI.

Referenced by activate().

Referenced by activate(), deactivate(), and update().

Referenced by activate(), and deactivate().

Interface to Ogre.

Referenced by activate(), deactivate(), and update().

Interface to GUI.

Referenced by activate(), deactivate(), and update().

Reference to input management.

Referenced by activate(), deactivate(), update(), windowFocusChanged(), and windowResized().

Special input state for master input.

Referenced by activate(), and deactivate().

Key binder for master key bindings.

Referenced by activate(), and deactivate().

Keeps track of SoundBase objects.

Referenced by activate(), and deactivate().


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

Generated on Tue Jul 28 16:22:33 2009 for Orxonox by  doxygen 1.5.6