Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Moteur3D::AppStarter_ObjectViewer Class Reference

AppStarter_ObjectViewer is an application starter that gives you the required minimum to start an application, plus some features. It consists in a window displaying an orthonormal base that you can rotate around using the mouse, functions to handle this window as well as inputs (mouse and keyboard) and events (resize, draw...). Most if not all of these functions are overridable. More...

#include <AppStarter_ObjectViewer.h>

Inheritance diagram for Moteur3D::AppStarter_ObjectViewer:

Moteur3D::AppStarter_3DApplication Moteur3D::IEventManager List of all members.

Public Member Functions

 AppStarter_ObjectViewer (WindowParams *params)
 Constructor.
 ~AppStarter_ObjectViewer ()
 Destructor.
virtual void Start ()
 Starts the window and its features. this involves creating and showing the window, initializing all the openGL stuff, and running the main loop. IMPORTANT : this function, as it calls function Run(), does NOT return until the window is closed. Once you're in, you can still control your app inside OnRenderScene and OnIdle, for example.

Protected Member Functions

virtual void InitObject ()
 Initialises the object to be displayed. Called once before the first display.
virtual void DisplayObject ()
 Displays the object to be shown. Called by OnRenderScene() at every frame.
virtual void InitGL ()
 Initialises all the OpenGL stuff such as modelview matrix, Z-buffer and so on.
virtual void OnRenderScene ()
 This function is called when the display needs a new frame to be rendered. Put all display stuff in it.
virtual void OnMouseMove (const MouseInformations *mouseInfo)
 This function is called every time the mouse is moved inside the window's borders.
virtual void OnMouseWheel (const MouseInformations *mouseInfo, short displacement)
 This function is called every time the wheel is used inside the window's borders.

Protected Attributes

SphericalCamera m_camera
 Camera used to rotate around the object.
int m_GLLists
 Display lists used for our axes.

Detailed Description

AppStarter_ObjectViewer is an application starter that gives you the required minimum to start an application, plus some features. It consists in a window displaying an orthonormal base that you can rotate around using the mouse, functions to handle this window as well as inputs (mouse and keyboard) and events (resize, draw...). Most if not all of these functions are overridable.


Constructor & Destructor Documentation

Moteur3D::AppStarter_ObjectViewer::AppStarter_ObjectViewer WindowParams *  params  ) 
 

Constructor.

Parameters:
params Windows parameters needed for instanciation

Moteur3D::AppStarter_ObjectViewer::~AppStarter_ObjectViewer  ) 
 

Destructor.


Member Function Documentation

virtual void Moteur3D::AppStarter_ObjectViewer::DisplayObject  )  [protected, virtual]
 

Displays the object to be shown. Called by OnRenderScene() at every frame.

virtual void Moteur3D::AppStarter_ObjectViewer::InitGL  )  [protected, virtual]
 

Initialises all the OpenGL stuff such as modelview matrix, Z-buffer and so on.

Reimplemented from Moteur3D::AppStarter_3DApplication.

virtual void Moteur3D::AppStarter_ObjectViewer::InitObject  )  [protected, virtual]
 

Initialises the object to be displayed. Called once before the first display.

virtual void Moteur3D::AppStarter_ObjectViewer::OnMouseMove const MouseInformations mouseInfo  )  [protected, virtual]
 

This function is called every time the mouse is moved inside the window's borders.

Parameters:
mouseInfo mouse informations, such as position, button states etc.

Reimplemented from Moteur3D::AppStarter_3DApplication.

virtual void Moteur3D::AppStarter_ObjectViewer::OnMouseWheel const MouseInformations mouseInfo,
short  displacement
[protected, virtual]
 

This function is called every time the wheel is used inside the window's borders.

Parameters:
mouseInfo Mouse informations, such as position, button states etc.
displacement wheel displacement. Is a multiple of 120, and can be positive or negative depending on the wheel's rotation.

Reimplemented from Moteur3D::AppStarter_3DApplication.

virtual void Moteur3D::AppStarter_ObjectViewer::OnRenderScene  )  [protected, virtual]
 

This function is called when the display needs a new frame to be rendered. Put all display stuff in it.

Reimplemented from Moteur3D::AppStarter_3DApplication.

virtual void Moteur3D::AppStarter_ObjectViewer::Start  )  [virtual]
 

Starts the window and its features. this involves creating and showing the window, initializing all the openGL stuff, and running the main loop. IMPORTANT : this function, as it calls function Run(), does NOT return until the window is closed. Once you're in, you can still control your app inside OnRenderScene and OnIdle, for example.

Reimplemented from Moteur3D::AppStarter_3DApplication.


Member Data Documentation

SphericalCamera Moteur3D::AppStarter_ObjectViewer::m_camera [protected]
 

Camera used to rotate around the object.

int Moteur3D::AppStarter_ObjectViewer::m_GLLists [protected]
 

Display lists used for our axes.


The documentation for this class was generated from the following file:
Generated on Sat Oct 15 15:05:51 2005 for Moteur3D by  doxygen 1.4.4