Wartbed:Framework

From Dark Omen Wiki

(Difference between revisions)
Jump to: navigation, search
(Namespaces)
Line 19: Line 19:
:}
:}
</tt>
</tt>
 +
 +
==Input Listeners==
 +
OGRE and WARTBED uses listener objects to capture and respond to user input. The raw input is then promulgated to event managers and/or the GUI system for handling. Gererally, WARTBED creates the appropriate or sufficient listener objects by default, replacing the old:
 +
 +
* When OGRE is initialised through <code>ogre::BootSystem()</code> basic inert listeners are created. These are unresponsive and cause no events.
 +
* When CEGUI is initialised through <code>ogre::InitialiseCEGUI()</code> <code>wb::gui::KeyListener</code> and <code>wb::gui::MouseListener</code> objects are created. These objects forward raw input into the GUI system.
 +
* When the <code>Wartbed</code> object is created (first time <code>Wartbed::getInstance()</code> is called) basic <code>wb::KeyListener</code> and <code>wb::MouseListener</code> (which are aliases for <code>wb::input::KeyListener</code> and <code>wb::input::MouseListener</code>) are created. These listeners cause WARTBED input events but are unconcerned with the GUI.
 +
* When the GUI is initialised through <code>Wartbed::initialiseGUI()</code> (when the <code>Wartbed::GUI</code> singleton  is first created) default listeners inheriting from both <code>input::*Listener</code> and <code>gui::*Listener</code> are created.
 +
 +
If further specialisation is required appropriate classes must be defined by the client application.
==Classes==
==Classes==

Revision as of 19:38, 13 March 2009

Stub page the may be updated as I go along. Does not in anyway represent the current state of the WARTBED code base.

Reference for WARTBED development framework

Namespaces

wb { main WARTBED namespace }
{
WARTBED-common namespaces
ogre { all things OGRE are encapsulated here }
input { all input-related aspects are collected here }
camera { enums for controlling a WARTBED Camera object }
gui { all things CEGUI and GUI are encapsulated here }
Modules
darkomen { Code specific to handle Warhammer: Dark Omen }
}

Input Listeners

OGRE and WARTBED uses listener objects to capture and respond to user input. The raw input is then promulgated to event managers and/or the GUI system for handling. Gererally, WARTBED creates the appropriate or sufficient listener objects by default, replacing the old:

  • When OGRE is initialised through ogre::BootSystem() basic inert listeners are created. These are unresponsive and cause no events.
  • When CEGUI is initialised through ogre::InitialiseCEGUI() wb::gui::KeyListener and wb::gui::MouseListener objects are created. These objects forward raw input into the GUI system.
  • When the Wartbed object is created (first time Wartbed::getInstance() is called) basic wb::KeyListener and wb::MouseListener (which are aliases for wb::input::KeyListener and wb::input::MouseListener) are created. These listeners cause WARTBED input events but are unconcerned with the GUI.
  • When the GUI is initialised through Wartbed::initialiseGUI() (when the Wartbed::GUI singleton is first created) default listeners inheriting from both input::*Listener and gui::*Listener are created.

If further specialisation is required appropriate classes must be defined by the client application.

Classes

namespace ::
Symbol #include Description
Wartbed Wartbed.h Framework initialisation object. When created will boot OGRE and initialise all basic facilities.


namespace wb
Symbol #include Description
Camera wb_Kernel.h Versatile camera abstraction that is designed for automate movement, focusing, swiveling, circling and orbiting operations.
Personal tools
communication