This reference page is linked to from the following overview topics: 3DXI Property Containers, 3DXI Node, 3DXI Objects, 3DXI Splines, 3DXI Modifiers.
Simple wrapper for 3ds Max objects.
This is heart of the interaction with 3ds Max objects. 3ds Max
objects are converted to IGame objects to provide simpler
interfaces. Specific support is given to Meshes, Splines, Helper
(including bones) and Cameras. Any object that is not supported by
IGame directly is supported as a generic object, so that properties
can be extracted easily. At the present time IGame only supports
Geom Objects that can be converted to a Tri Object.
A note about XRef items. IGame will search out XRef Objects and
store them as IGameXrefObject. External file names and proxies can
be accessed by casting IGameObject* to IGameXrefObject*
Some of the interfaces returned by IGameObject require that
the nodes be parsed by IGame first.
#include <IGameObject.h>
Public Types |
|
enum | ObjectTypes
{ IGAME_UNKNOWN, IGAME_LIGHT, IGAME_MESH, IGAME_SPLINE, IGAME_CAMERA, IGAME_HELPER, IGAME_BONE, IGAME_IKCHAIN, IGAME_XREF } |
Various IGame Object types. More... |
|
enum | MaxType
{ IGAME_MAX_UNKNOWN, IGAME_MAX_GEOM, IGAME_MAX_SHAPE, IGAME_MAX_LIGHT, IGAME_MAX_CAMERA, IGAME_MAX_BONE, IGAME_MAX_HELPER } |
Various 3ds Max Object types. More... |
|
Public Member Functions |
|
IGameObject () | |
Default constructor. |
|
IGAMEEXPORT void | GetBoundingBox (Box3 &bb) |
The bounding box of the object. |
|
IGAMEEXPORT bool | IsRenderable () |
Check if object renderable. |
|
virtual ObjectTypes | GetIGameType ()=0 |
The IGame object type. |
|
IGAMEEXPORT Object * | GetMaxObject () |
Access to the actual 3ds Max object.
|
|
IGAMEEXPORT MaxType | GetMaxType () |
The 3ds Max object type. |
|
IGAMEEXPORT int | GetNumModifiers () |
The number of modifiers active on the
object. |
|
IGAMEEXPORT IGameModifier * | GetIGameModifier (int index) |
Access to IGame modifier. |
|
IGAMEEXPORT | IGameObject (INode *node) |
The IGameObject constructor.
|
|
IGAMEEXPORT bool | CastShadows () |
Check if Object
casts shadows. |
|
IGAMEEXPORT bool | IsObjectSkinned () |
Check if object skinned. |
|
IGAMEEXPORT IGameSkin * | GetIGameSkin () |
Access to the Skin interface. |
|
IGAMEEXPORT bool | IsObjectXRef () |
Check if XRef object. |
|
IGAMEEXPORT GMatrix | GetIGameObjectTM () |
Access to the ObjectTM. |
|
virtual bool | InitializeData () |
Extract the 3ds Max data into IGame data.
|
|
virtual | ~IGameObject ()=0 |
Protected Member Functions |
|
void | SetNode (INode *n) |
Protected Attributes |
|
INode * | gameNode |
Object * | gameObject |
enum ObjectTypes |
Various IGame Object types.
These are the objects supported by IGame
enum MaxType |
IGameObject | ( | ) |
Default constructor.
IGAMEEXPORT IGameObject | ( | INode * | node | ) |
The IGameObject constructor.
*node | The 3ds Max node to initialise |
virtual ~IGameObject | ( | ) | [pure virtual] |
void SetNode | ( | INode * | n | ) | [protected] |
IGAMEEXPORT void GetBoundingBox | ( | Box3 & | bb | ) |
The bounding box of the object.
bb | The Box3 to receive the value |
IGAMEEXPORT bool IsRenderable | ( | ) |
virtual ObjectTypes GetIGameType | ( | ) | [pure virtual] |
The IGame object type.
Return the Type of IGameObject it represents
IGAMEEXPORT Object* GetMaxObject | ( | ) |
Access to the actual 3ds Max object.
Access to the actual 3ds Max object, if further direct access needed
IGAMEEXPORT MaxType GetMaxType | ( | ) |
The 3ds Max object type.
This lets the developer know what type of object - Light, Geom, Helper etc... This is different from the IGame types, as these may group more than one type of 3ds Max object together. The information can be used to cast Object returned from IGameObject::GetMaxObject to the appropriate class.
IGAMEEXPORT int GetNumModifiers | ( | ) |
The number of modifiers active on the object.
IGAMEEXPORT IGameModifier* GetIGameModifier | ( | int | index | ) |
Access to IGame modifier.
Get a pointer to the IGame representation of the modifier
index | The index of the modifier to return |
IGAMEEXPORT bool CastShadows | ( | ) |
IGAMEEXPORT bool IsObjectSkinned | ( | ) |
Check if object skinned.
Is object skinned with either Physique of Skin
IGAMEEXPORT IGameSkin* GetIGameSkin | ( | ) |
Access to the Skin interface.
IGAMEEXPORT bool IsObjectXRef | ( | ) |
IGAMEEXPORT GMatrix GetIGameObjectTM | ( | ) |
Access to the ObjectTM.
Get the ObjectTM. This is the matrix needed to calculate world space
virtual bool InitializeData | ( | ) | [inline, virtual] |
Extract the 3ds Max data into IGame data.
Some extraction processes are time and memory consuming. This method allows the developer to specify when they want the data to be converted - this prevents any unwanted data being converted. This is important for IGameMesh class - if you are just after parameter data, you don't want the whole vertex array being sorted. Calling this tells the object that you want the data be converted.
{return false;}
Object* gameObject
[protected] |