Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   Compound Members  

CSLScene Class Reference

#include <Scene.h>

List of all members.

Public Methods


Detailed Description

CSLScene Class

This is the top level object for a dotXSI abstraction using the SemanticLayer. From this class, you can access all the models, primitives, material etc. contained in the dotXSI.


Member Function Documentation

CSLAmbience * CSLScene::Ambience  
 

Gets the ambience object.

Returns:
CSLAmbience* The ambience object

CSLAngle * CSLScene::Angle  
 

Gets the Angle object

Returns:
CSLAngle* The Angle object

SLTemplateCallback * CSLScene::Callback SI_Char *    in_pName
 

Get a callback by name

Parameters:
SI_Char  * Template name
Returns:
SLTemplateCallback* Pointer to a callback struct

SI_Error CSLScene::Close  
 

Close the opened/created file.

Returns:
SI_Error Error code.

CSLAmbience * CSLScene::ConnectAmbience CSLAmbience   in_pNewAmbience
 

Connect an existing CSLAmbience object to the scene

Parameters:
CSLAmbience  * The new CSLAmbience
Returns:
CSLAmbience* The old CSLAmbience

CSLAngle * CSLScene::ConnectAngle CSLAngle   in_pNewAngle
 

Connect an existing CSLAngle object to the scene

Parameters:
CSLAngle  * The new CSLAngle
Returns:
CSLAngle* The old CSLAngle

CSLCoordinateSystem * CSLScene::ConnectCoordinateSystem CSLCoordinateSystem   in_pNewCoordinateSystem
 

Connect an existing CSLCoordinateSystem object to the scene

Parameters:
CSLCoordinateSystem  * The new CSLCoordinateSystem
Returns:
CSLCoordinateSystem* The old CSLCoordinateSystem

CSLEnvelopeList * CSLScene::ConnectEnvelopeList CSLEnvelopeList   in_pNewEnvList
 

Connect an existing CSLEnvelopeList object to the scene

Parameters:
CSLEnvelopeList  * The new CSLEnvelopeList
Returns:
CSLEnvelopeList* The old CSLEnvelopeList

CSLFileInfo * CSLScene::ConnectFileInfo CSLFileInfo   in_pNewFileInfo
 

Connect an existing CSLFileInfo object to the scene

Parameters:
CSLFileInfo  * The new CSLFileInfo
Returns:
CSLFileInfo* The old CSLFileInfo

CSLFog * CSLScene::ConnectFog CSLFog   in_pNewFog
 

Connect an existing CSLFog object to the scene

Parameters:
CSLFog  * The new CSLFog
Returns:
CSLFog* The old CSLFog

CSLImageLibrary * CSLScene::ConnectImageLibrary CSLImageLibrary   in_pImageLibrary
 

Connect Image library

Parameters:
in_pImageLibrary  Pointer to the pre-allocated image library to connect
Returns:
Pointer to the newly connected image library or null if there's already an image library or if the parser does not support 3.6 templates
Note:
The parser must support 3.6 templates in order to connect an image library

CSLMaterialLibrary * CSLScene::ConnectMaterialLibrary CSLMaterialLibrary   in_pNewMaterialLibrary
 

Connect an existing CSLMaterialLibrary object to the scene

Parameters:
CSLMaterialLibrary  * The new CSLMaterialLibrary
Returns:
CSLMaterialLibrary* The old CSLMaterialLibrary

CSLSceneInfo * CSLScene::ConnectSceneInfo CSLSceneInfo   in_pToConnect
 

Connect an existing CSLSceneInfo object to the scene

Parameters:
CSLSceneInfo  * The new CSLSceneInfo
Returns:
CSLSceneInfo* The old CSLSceneInfo

CSLCoordinateSystem * CSLScene::CoordinateSystem  
 

Gets the coordinatesystem object

Returns:
CSLCoordinateSystem* The CoordinateSystem object

SI_Error CSLScene::Create SI_Int    in_nVersionMajor,
SI_Int    in_nVersionMinor
 

Create a new dotXSI file.

Parameters:
SI_Int  Major version of the file.
SI_Int  Minro version of the file.
Returns:
SI_Error Error code.

SI_Error CSLScene::Create SI_Char *    in_szFileName,
SI_Int    in_nVersionMajor,
SI_Int    in_nVersionMinor
 

Create a new dotXSI file.

Parameters:
SI_Char  * File to create.
SI_Int  Major version of the file.
SI_Int  Minro version of the file.
Returns:
SI_Error Error code.

CSLEnvelopeList * CSLScene::CreateEnvelopeList  
 

Creation of envelope list

Returns:
CSLEnvelopeList*

CSLFog * CSLScene::CreateFog  
 

Creation of Fog

Returns:
CSLFog*

CSLImageLibrary * CSLScene::CreateImageLibrary  
 

Creation of an Image Library

Returns:
CSLImageLibrary*
Note:
Introduced in 3.6

SI_Error CSLScene::DestroyEnvelopeList  
 

Removes the EnvelopeList object

Returns:
SI_Error Error code

SI_Error CSLScene::DestroyFog  
 

Removes the Fog object

Returns:
SI_Error Error code

SI_Error CSLScene::DestroyImageLibrary  
 

Removal of the Image Library

Returns:
Error code
Note:
Introduced in 3.6

CSLEnvelopeList * CSLScene::EnvelopeList  
 

Gets the EnvelopeList object

Returns:
CSLEnvelopeList* The EnvelopeList object

CSLFileInfo * CSLScene::FileInfo  
 

Gets the FileInfo object

Returns:
CSLFileInfo* The FileInfo object

CSIBCString & CSLScene::FileName  
 

Get the filename of the current scene.

Gets the filename for the current scene

Returns:
CSIBCString& The filename

CSLModel * CSLScene::FindModel SI_Char *    in_szModelName
 

Find a SI_Model by name

Parameters:
SI_Char  * The model's name
Returns:
CSLModel* The model, or NULL if not found.

CSLModel * CSLScene::FindModelRecursively SI_Char *    in_szModelName,
CSLModel   in_pModel
 

Find a SI_Model, recursively.

Parameters:
SI_Char  * The model's name
CSLModel  * A Pointer to a CSLModel
Returns:
CSLModel* The model, or NULL if not found.

CSLAnimatableType * CSLScene::FindParameter SI_Char *    in_szParameterName
 

Find a parameter by name.

Parameters:
SI_Char  * The XSI path to the parameter (see below)
Returns:
CSLAnimatableParameter* The parameter.
Note:
When we say "the XSI path to a parameter", we mean the scripting name for the parameter. For example "MyModel.kine.local.posx" would refer to the X component of the position in the model "MyModel" transformation matrix.

CSLFog * CSLScene::Fog  
 

Gets the Fog object

Returns:
CSLFog* The Fog object

CSLImageLibrary * CSLScene::GetImageLibrary  
 

Get the image library

Returns:
CSLImageLibrary Pointer to the image library or null if there's none

CSLMaterialLibrary * CSLScene::GetMaterialLibrary  
 

Gets the MaterialLibrary object

Returns:
CSLMaterialLibrary* The MaterialLibrary object

SI_Error CSLScene::GetRefCount CSLTemplate **    in_ppObjects,
SI_Int **    out_ppRefCounts,
SI_Int    in_iObjectCount,
CSLTemplate::ETemplateType    in_eType
 

Gets the refcount (how many others uses the specified template)

Parameters:
in_ppObjects  which objects to check
out_ppRefCounts  Counts for each one
in_iObjectCount  How many objects in the array
in_eType  Types (either CSLTemplate::SI_MODEL or CSLTemplate::SI_MATERIAL)

SI_Error CSLScene::GetValue SI_Char *    in_szParameterName,
SI_Float *    out_pfValue
 

Gets a parameter value.

Parameters:
SI_Char  * The XSI path to the parameter (see below)
SI_Float  * The parameter's value
Returns:
SI_Error Error code

CSLLogger * CSLScene::Logger  
 

Gets the Logger object

Returns:
CSLLogger* The Logger object

SI_Error CSLScene::Open SI_Char *    in_szFileName,
SI_READ_CALLBACK_FNC    in_pFunc
 

Open a dotXSI file for reading and writing. The file must exist for the function to succeed.

Parameters:
SI_Char  * File to open.
SI_READ_CALLBACK_FNC  read callback
Returns:
SI_Error Error code.

SI_Error CSLScene::Open SI_Char *    in_szFileName
 

Open a dotXSI file for reading and writing. The file must exist for the function to succeed.

Parameters:
SI_Char  * File to open.
Returns:
SI_Error Error code.

CXSIParser * CSLScene::Parser  
 

Gets the CXSIParser object

Returns:
CXSIParser* the CXSIParser object

SI_Error CSLScene::Read  
 

Populate the semantic layer with data present in the file.

Returns:
SI_Error Error code.

SI_Error CSLScene::RegisterCallback SI_Char *    in_pName,
SLTemplateCallback   in_pTemplateCallback
 

Register a new template callback

Parameters:
SI_Char  * The template name
SLTemplateCallback  * The template callback structure
Returns:
SI_Error Error code
Example - Adding a new template callback
                //
                // Remember the native callbacks
                //

                SLTemplateCallback* l_pOldCallback = Scene->Callback ( "SI_Mesh" );
                memcpy ( &m_sNativeCallbacks, l_pOldCallback, sizeof ( SLTemplateCallback ));

                //
                // Create new set of callbacks
                //

                SLTemplateCallback      l_NewCallbacks;
                memcpy ( &l_NewCallbacks, l_pOldCallback, sizeof ( SLTemplateCallback ));

                //
                // Add a PostChilren callback and keep the others to the default
                //

                l_NewCallbacks.m_PostChildrenCallback  = SIMeshPostRTPCallback;
                
                //
                // Register the new callbacks
                //

                in_pCurrentScene->RegisterCallback ( "SI_Mesh", &l_NewCallbacks );

CSLModel * CSLScene::Root  
 

Gets the Root Model

Returns:
CSLModel* The Root Model

CSLSceneInfo * CSLScene::SceneInfo  
 

Gets the SceneInfo object

Returns:
CSLSceneInfo* The SceneInfo object

SI_Void CSLScene::SetReadCallback SI_READ_CALLBACK_FNC    in_pfncCallback [inline]
 

Sets the callback that gets call for reading every template

Parameters:
in_pfncCallback  Callback function

SI_Error CSLScene::SetValue SI_Char *    in_szParameterName,
SI_Float    in_fValue
 

Sets a parameter value.

Parameters:
SI_Char  * The XSI path to the parameter (see below)
SI_Float  The parameter's new value
Returns:
SI_Error Error code

SI_Void CSLScene::SetWarningCallback SI_WARNING_CALLBACK_FNC    in_pfncCallback [inline]
 

Sets the callback that receives warning messages

Parameters:
in_pfncCallback  Callback function

SI_Bool CSLScene::SupportsTemplates SI_Int    in_nMajor,
SI_Int    in_nMinor
 

Checks if the parser of the scene supports templates of a specific version of the dotXSI format

Parameters:
in_nMajor  Major version of the parser
in_nMinor  Minor version of the parser
Returns:
SI_Bool True if the version is supported, false otherwise

SI_Error CSLScene::UnregisterAllCallbacks  
 

Unregister all template callback

Returns:
SI_Error Error code

SI_Error CSLScene::UnregisterCallback SI_Char *    in_pName
 

Unregister a template callback

Parameters:
SI_Char  * The template name
Returns:
SI_Error Error code

SI_Error CSLScene::Write SI_Char *    in_szFileName
 

Write a dotXSI file containing the data present in the semantic layer.

Parameters:
SI_Char  * File to create.
Returns:
SI_Error Error code.

SI_Error CSLScene::Write  
 

Write a dotXSI file containing the data present in the semantic layer.

Returns:
SI_Error Error code.


The documentation for this class was generated from the following files: © Copyright 2001-2003 Avid Technology, Inc. All rights reserved.

© Copyright 2001-2003 Avid Technology, Inc. All rights reserved.