OpenScene

Introduced

v1.0

Categories

file

Description

Opens a scene from a file. A scene file (.scn) is required to execute this command.

This command is accessed from the main menu under File->Open

Scripting Syntax

OpenScene( [SceneFileName], [Confirm], [ApplyAuxiliaryData] );

Parameters

Parameter Type Description
SceneFileName String Full path name of the scene

Default Value: A file browser pops up

Confirm Boolean True to prompt user to save the scene if the scene contains unsaved changes

Default Value: True

ApplyAuxiliaryData Boolean True to apply previously loaded auxiliary data once the scene is opened. You can use the '-auxiliary_data' command line argument when starting Softimage to open an Auxiliary Data file. Please note that Auxiliary Data is applied prior to siOnEndSceneOpen events. Please refer to About Auxiliary Files for more details concerning the Auxiliary Data file format and usage.

Default Value: False

Examples

VBScript Example

'
' This script demonstrates how to open scenes. 
' 
NewScene , False
' Now find a scene to open.
scene_file = XSIUtils.BuildPath( _
        Application.InstallationPath(siFactoryPath), _
        "Data", "XSI_SAMPLES", "Scenes", "Rendering", _
        "Rendertree_Light_Rainbow.scn" _
)
OpenScene scene_file, False
' Now open it again, except apply auxiliary data.
OpenScene scene_file, False, True

See Also

NewScene SaveScene Auxiliary Files