S3DSceneGraphUtils

This class is used to manipulate the scenegraph.

Interface Methods

Descriptions

S3DSceneGraphUtils

Constructor

~S3DSceneGraphUtils

Destructor

Init

Initializes the object for use

GetCoreServices

Returns the Shockwave 3D§ core services object

GetSceneGraph

Returns the current scenegraph

GetLightPalette

Returns the current Light Palette

GetMaterialPalette

Returns the current Material Palette

GetModelPalette

Returns the current Model Palette

GetMotionPalette

Returns the current Motion palette

GetNodePalette

Returns the current Node palette

GetShaderPalette

Returns the current Shader palette

GetTexturePalette

Returns the current Texture palette

AddView

Adds a new view to the scene

AddSkeletonToModelResource

Adds a skeleton modifier to the model resource

AddMotionResource

Adds a motion resource to the motion palette and returns the new motion resource

CompressMotionTracks

Eliminates duplicate frames from the Motion Resource

AddSkeletonParamToNode

Adds a skeleton modifier param to a node

NodeSetTexturePriorities

Sets the priority on all textures used by the node

StylePaletteSetTexturePriorities

Sets the priority on all textures referenced by the style palette

ShaderSetTexturePriorities

Sets the priority on all textures referenced by the style palette

FindWorldBoundingSphere

Finds the bounding sphere for the world


S3DSceneGraphUtils::S3DSceneGraphUtils ()

Constructor method.

Parameters:

None

Return Values:

None


S3DSceneGraphUtils::~S3DSceneGraphUtils ()

Destructor method.

Parameters:

None

Return Values:

None


S3DSceneGraphUtils::AddMotionResource (CIFXString * in_MotionName, U32 *, IFXMotionResource **)

This method adds a motion resource to the motion palette and returns the new motion resource.

Parameters:

in_MotionName

Name of the motion resource to add

*

ID number of the motion resource added

**

The motion resource returned

Return Values


S3DSceneGraphUtils::AddSkeletonParamToNode (IFXNode * in_pNode, CIFXString * in_MotionName, IFXSkeletonModifier * in_pSkeleton)

This method adds a skeleton modifier param to a node.

Parameters:

in_pNode

The node to receive the new skeleton modifier

in_MotionName

The name of the motion resource to set as active on the new parameters

in_pSkeleton

The skeleton modifier to link to the new parameters

Return Values


S3DSceneGraphUtils::AddSkeletonToModelResource(IFXModelResource* in_pMR, IFXSkeletonModifier** out_pSkeleton)

This method adds a skeleton modifier to the model resource.

Parameters:

in_pMR

The model resource to add the skeleton modifier to

out_pSkeleton

The skeleton modifier that was added

Return Values


S3DSceneGraphUtils::AddView (CIFXString * in_pViewName, IFXView ** out_ppView)

This method creates a new view, adds it to the node palette, and returns the created view.

Parameters:

in_pViewName

The name of the view to add

out_ppView

The view added to the scene

Return Values


S3DSceneGraphUtils::CompressMotionTracks (IFXMotionResource * in_MotionResource)

This method eliminates duplicate frames from the motion resource.

Parameters:

in_MotionResource

The motion resource to compress

Return Values


S3DSceneGraphUtils::GetCoreServices ()

This method returns the Shockwave 3D core services object.

Parameters:

None

Return Values:

IFXCoreServices *

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetLightPalette ()

This method returns the current light palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetMaterialPalette ()

This method returns the current material palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetModelPalette ()

This method returns the current model palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetMotionPalette ()

This method returns the current motion palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetNodePalette ()

This method returns the current node palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetSceneGraph ()

Returns the current scenegraph.

Parameters:

None

Return Values:

IFXSceneGraph *

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetShaderPalette ()

This method returns the current shader palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::GetTexturePalette ()

This method returns the current texture palette.

Parameters:

None

Return Values:

IFXPalette*

Comments:

Performs an addref on the pointer returned, so you need to release it when you are finished with it.


S3DSceneGraphUtils::Init ()

This method initializes the object for use. It creates CoreServices and Scenegraph, and grabs pointers to all the palettes.

Parameters:

None

Return Values


S3DSceneGraphUtils::FindWorldBoundingSphere(IFXSGVector *pWorldBound)

This method Finds the bounding sphere for the world.

Parameters:

pWorldBound

The returned world bounding sphere

Return Values


S3DSceneGraphUtils::NodeSetTexturePriorities(IFXNode *pNode, U2 uInPriority)

This method Sets the priority on all textures used by the node.

Parameters:

pNode

The node whose textures are to be given the priority

uInPriority

The priority to set on all textures used by this node

Return Values


S3DSceneGraphUtils::StylePaletteSetTexturePriorities(IFXPalette *pStylePalette, U32 uInPriority, U32 uNumShaders)

This method sets the priority on all textures referenced by the style palette.

Parameters:

pStylePalette

The style palette whose textures are to be given the priority

uInPriority

The priority to set on all textures used by this style palette. Maxmimum priority = 0; higher numbers equal lower priority

uNumShaders

The number of shaders listed in each style palette entry

Return Values


S3DSceneGraphUtils::ShaderSetTexturePriorities(IFXShaderLitTexture *pShader, U2 uInPriority)

This method sets the priority on all textures referenced by the style palette.

Parameters:

pShader

The shader whose textures are to be given the priority

uInPriority

The priority to set on all textures used by this shader. Maxmimum priority = 0; higher numbers equal lower priority

Return Values

§See asterisked (*) statement at Legal Information © 2001 Intel Corporation.