Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

Using GBGraphics

Introduction

The GBGraphics module makes it easy to load SkeletalModel's and VertexModel's. The gbgraphics::Server is used for managing and rendering graphics objects. There are also options that can be set in the gbgraphics::Server to manipulate how things are rendered.

Server

The first step in using the gbgraphics::Server is to call Init(). Thereafter, Update() should be called. To shutdown the server call Destroy(). SetOption() manipulates how the server will render.

Models

A model is a combination of a mesh with animations. Models can be loaded from disk using the server's Load(). After a model has been loaded, a call to GetModel() will retrieve the model. Then a gbgraphics::ModelState can be instantiated. A ModelState is an instance of a gbgraphics::Model. gbgraphics::SkeletalMesh's can be combined with gbgraphics::SkeletalMotion's into a gbgraphics::SkeletalModel allowing keyframed skeletal animation. An instance of a model can be instantiated from the server. gbgraphics::VertexModel's all use vertex animation. VertexModel's have animations embedded with the mesh. To render a model, make sure to call ModelState::Update() it first. This will animate the model's mesh and return a pointer to a gbgraphics::MeshState which should be attached to the server for rendering by calling the server's AttachMeshState().

SkeletalModels and Animation

gbgraphics::SkeletalModel's allow animation blending by using gbgraphics::Track's. gbgraphics::TrackCycle is designed for whole-body, cyclical animations like walking. gbgraphics::TrackOverlay is designed for local animations that override cyclical animations like waving.


Generated on Mon Sep 2 14:52:32 2002 for GunBuster Engine by doxygen1.2.17