Environments Messages

Action Messages

  • ENVIRONMENT_ADD_GENERIC_TO_SCENE - Adds a generic environment into scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_GENERIC_ADDED. This default maximum wait time for this message is 60.

    Parameters:

    • libraryEnvId (unicode) - The ID of the environment in the library being added.

    • envName (unicode) - The new name for the environment, it can be empty string and then a new one will be generated.

    • envFilePath (unicode) - The path to the selected environment file, it can be empty string and then no file is set.

  • ENVIRONMENT_ADD_TO_SCENE - Adds an environment into scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_ADDED. This default maximum wait time for this message is 60.

    Parameters:

    • libraryEnvId (unicode) - The ID of the environment in the library being added.

    • envName (unicode) - The new name for the environment, it can be empty string and then a new one will be generated.

  • ENVIRONMENT_CHANGE_BACKDROP_IMAGE - For each specified environment, overrides the backdrop to the given value. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_BACKDROP_IMAGE_CHANGED. This default maximum wait time for this message is 10.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments to affect.

    • backdropFilename (unicode) - The full path of the backdrop image.

    • backdropMaterialParameters (tuple) - Material parameters to be used in the backdrop shader. The default tuple for the parameters is ( 'planar', '0.0', '0.0', '1.0', '', '', '128.0', '0.0', '1.0' ). The first parameters are mapping, horizon, horizontal offset and scale. The other parameters should be assigned their default values.

  • ENVIRONMENT_CHANGE_BACKPLATE_PARAMETERS - For each specified environment, overrides the backdrop parameters. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_BACKPLATE_PARAMETERS_CHANGED. This default maximum wait time for this message is 10.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments to affect.

    • parameters (tuple) - The parameter values for fit type: (0 - no fit; 1 - horizontal; 2 - vertical); scale (default 1); horizontal and vertical offsets (default 0).

  • ENVIRONMENT_CHANGE_INITIAL - Sets the startup environment in the scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_INITIAL_CHANGED. This default maximum wait time for this message is 10.

    Parameters:

    • envId (unicode) - The ID of the new startup environment.

  • ENVIRONMENT_CHANGE_LIGHTING_PARAMETERS - For each specified environment, sets the lighting parameters to the given values. If a parameter does not exist, it will be created if 'forceCreation' is set to True. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_LIGHTING_PARAMETERS_CHANGED. This default maximum wait time for this message is 10.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments to affect.

    • parameterNames (tuple) - A tuple of the names of the parameters to change: 'backdrop', 'diffuseCube', 'reflectCube', 'specularCube', 'backplate', 'envImage', 'globalIBLContrastPivot', 'globalIBLContrastValue', 'globalIBLGainColor', 'globalIBLGainSource', 'globalIBLGainValue', 'globalIBLGammaValue', 'globalIBLSatValue', 'kGlobalIBLMatrix'. (See "Class ParameterConstant" in the Showcase API Reference documentation.)

    • parameterType (int) - The type of the value: 0 - String; 1 - Double; 2 - Array of 2 doubles; 3 - Array of 3 doubles; 4 - Array of 4 doubles; 5 - AffineMatrix; 6 - File. (See 'enum Type' under "awSupport:Parameter" in the Showcase API Reference documentation.)

    • parameterValue (unicode) - A string representing the value to set on the parameter.

    • forceCreation (bool) - True to create the parameter if it doesn't exist.

  • ENVIRONMENT_DELETE_FROM_LIBRARY - Deletes a given environment from the library. The environment is physically deleted from the disk. Note: This operation is not undoable. This message will trigger the following response messages: ENVIRONMENT_DELETED. This default maximum wait time for this message is 60.

    Parameters:

    • libraryEnvId (unicode) - The ID of the environment in the library being deleted.

  • ENVIRONMENT_DUPLICATE - Duplicates an environment currently in the scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_DUPLICATED. This default maximum wait time for this message is 10.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene being duplicated.

  • ENVIRONMENT_LIBRARY_ADD - Adds a new environment library path to the user preferences. If the specified folder does not exist, it will also create a folder for the new library. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_LIBRARY_ADDED. This default maximum wait time for this message is 60.

    Parameters:

    • libraryPath (unicode) - Path of the environment library being added.

  • ENVIRONMENT_LIBRARY_LOAD - Loads the environment library. This message will trigger the following response messages: ENVIRONMENT_LIBRARY_LOADED. This default maximum wait time for this message is 10.

  • ENVIRONMENT_LIBRARY_REMOVE - Removes an environment library path from the user preferences. This message is undoable and broadcastable.

    Parameters:

    • libraryPath (unicode) - The path to an existing environment library.

  • ENVIRONMENT_LOAD - Loads the environment with the specified ID. The environment ID must refer to an existing environment in the scene. This message is undoable and broadcastable. This message will trigger the following response messages: MODEL_IMPORT_DISPLAYED_ALL. This default maximum wait time for this message is 60.

    Parameters:

    • environmentIds (unicode) - The ID of the environment to be loaded.

  • ENVIRONMENT_MODEL_REPLACE - Replaces current environment's model with the specified one, or reloades the model, if the specified filename is the same as the one of the current environment's model.

    Parameters:

    • modelImportId (unicode) - Id of the model import. If it is empty, a new model will be imported, otherwise, the model will be reloaded.

    • filename (unicode) - The filename of the model being imported.

  • ENVIRONMENT_POSITION_FLOOR_UNDER_MODELS - Translates the environment (z axis only) so that the environment's origin coincides with the bounding box of the model root. If there is no geometry in the scene, the call has no effect. This message is undoable. This message will trigger the following response messages: ENVIRONMENT_ROOT_TRANSFORM_CHANGED. This default maximum wait time for this message is 10.

  • ENVIRONMENT_REMOVE_FROM_SCENE - Removes an environment currently from the scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_REMOVED. This default maximum wait time for this message is 60.

    Parameters:

    • sceneEnvId (unicode) - The ID of the environment in the scene being removed.

  • ENVIRONMENT_RENAME - Renames an environment currently in the scene. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_RENAMED. This default maximum wait time for this message is 10.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene.

    • newName (unicode) - The new name for the environment.

  • ENVIRONMENT_RENAME_FROM_LIBRARY - Renames an environment in the library, this will rename the actual folder and all associated files in the environment folder. This message will trigger the following response messages: ENVIRONMENT_RENAMED_FROM_LIBRARY. This default maximum wait time for this message is 60.

    Parameters:

    • libraryEnvId (unicode) - The ID of the environment in the library being renamed.

    • newName (unicode) - The new name for the environment.

  • ENVIRONMENT_REQUEST_LIST - Requests that a new ENVIRONMENT_LIST message be issued.

  • ENVIRONMENT_RESOLVE - Resolves an environment from specified location. This message will trigger the following response messages: ENVIRONMENT_RESOLVED. This default maximum wait time for this message is 10.

    Parameters:

    • oldEnvId (unicode) - The ID of the environment in the scene that is marked NOT FOUND.

    • envFile (unicode) - The file path of the environment being resolved.

  • ENVIRONMENT_ROOT_TRANSFORM - Transforms the environment. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_ROOT_TRANSFORM_CHANGED. This default maximum wait time for this message is 10.

    Parameters:

    • scale (float) - The new scale of the environment.

    • translate (list) - The new center point of the environment.

  • ENVIRONMENT_SAVE_THUMBNAIL - Saves a thumbnail image for the environment in scene. This message will trigger the following response messages: ENVIRONMENT_THUMBNAIL_SAVED. This default maximum wait time for this message is 10.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene being set image

  • ENVIRONMENT_SAVE_TO_LIBRARY - Saves an new or modified environment into the library. This message will trigger the following response messages: ENVIRONMENT_SAVED. This default maximum wait time for this message is 10.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene being saved.

    • libraryPath (unicode) - The new library path for the environment.

    • forceToSaveAs (bool) - If set to True, the environment will be saved to a new name, otherwise, it will override an existing one if it already exists.

  • ENVIRONMENT_UI_SET_MODE - Shows or hides the Environments user interface.

    Parameters:

    • visible (bool) - True to show the Environments user interface, False to hide it.

  • ENVIRONMENT_UPDATE_LIST - Updates an environment list. This message is undoable and broadcastable. This message will trigger the following response messages: ENVIRONMENT_LIST. This default maximum wait time for this message is 10.

    Parameters:

    • envList (list) - List of environment IDs.

  • ENVIRONMENTS_SAVE_WITH_SCENE - Saves environments in scene with the scene. This default maximum wait time for this message is 10.

    Parameters:

    • fileName (unicode) - The name of the scene being saved.

Information Messages

  • ENVIRONMENT_CHANGED - Indicates that a new environment succesfully loaded.

    Parameters:

    • envId (unicode) - The ID of the new environment.

  • ENVIRONMENT_LIBRARY_REMOVED - Indicates that an environment library was removed.

    Parameters:

    • libraryPath (unicode) - The path to the environment library that was removed.

Response Messages

  • ENVIRONMENT_ADDED - Indicates that an environment in the scene was added.

    Parameters:

    • newEnvId (unicode) - The ID of the environment in the scene that was added.

    • newEnvName (unicode) - The new name for the environment.

  • ENVIRONMENT_BACKDROP_IMAGE_CHANGED - Indicates that the backdrop has been overridden for at least one environment.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments affected.

    • backdropFilename (unicode) - The full path of the backdrop image override.

    • newParameters (tuple) - Accepted parameters tuple. ( Preferred mapping, horizon, horizontalOffset, scale )

  • ENVIRONMENT_BACKPLATE_PARAMETERS_CHANGED - Indicates that the backdrop parameters have been modified for at least one environment.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments affected.

    • parameters (tuple) - The parameter values for fit type: 0 - no fit; 1 - horizontal; 2-vertical), scale; horizontal and vertical offsets.

  • ENVIRONMENT_DELETED - Indicates that an environment in the library was deleted.

    Parameters:

    • libraryEnvId (unicode) - The ID of the environment in the library that was deleted.

  • ENVIRONMENT_DUPLICATED - Indicates that an environment in the scene was duplicated.

    Parameters:

    • newEnvId (unicode) - The ID of the environment in the scene that was duplicated.

  • ENVIRONMENT_GENERIC_ADDED - Indicates that a generic environment was added into scene.

    Parameters:

    • newEnvId (unicode) - The ID of the environment in the scene that was added.

    • newEnvName (unicode) - The new name for the environment.

    • envFilePath (unicode) - The path to the selected environment file, it can be empty string and then the user has to select a file from with in the Create Environment Window

  • ENVIRONMENT_INITIAL_CHANGED - Indicates that a new startup environment has been set.

    Parameters:

    • envId (unicode) - The ID of the new startup environment.

  • ENVIRONMENT_LIBRARY_ADDED - Indicates that a new environment library was added.

    Parameters:

    • libraryPath (unicode) - The path to the environment library that was added.

  • ENVIRONMENT_LIBRARY_LOADED - Indicates that environment library has been loaded.

  • ENVIRONMENT_LIGHTING_PARAMETERS_CHANGED - Indicates that a lighting parameter has been changed on an environment.

    Parameters:

    • environmentIds (tuple) - A tuple of the IDs of the environments affected.

    • parameterNames (tuple) - A tuple of the names of the parameters that were changed.

    • parameterType (int) - The type of the value.

    • parameterValue (unicode) - A string representing the new value of the parameters.

  • ENVIRONMENT_LIST - Lists all environments available to the scene.

    Parameters:

    • envList (list) - List of environment IDs.

  • ENVIRONMENT_REMOVED - Indicates that an environment in the scene was removed.

    Parameters:

    • sceneEnvId (unicode) - The ID of the environment in the scene that was removed.

  • ENVIRONMENT_RENAMED - Indicates that an environment in the scene was renamed.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene that was renamed.

    • newName (unicode) - The new name for the environment.

  • ENVIRONMENT_RENAMED_FROM_LIBRARY - Indicates that an environment was renamed.

    Parameters:

    • OriginalLibraryEnvId (unicode) - The original ID of the environment that was renamed.

    • libraryEnvId (unicode) - The ID of the environment that was renamed.

    • newName (unicode) - The new name for the environment.

  • ENVIRONMENT_RESOLVED - Indicates that an environment was resolved.

    Parameters:

    • oldEnvId (unicode) - The ID of the environment in the scene that is marked NOT FOUND.

    • newEnvId (unicode) - The ID of the environment in the scene that was resolved.

  • ENVIRONMENT_ROOT_TRANSFORM_CHANGED - Indicates that the transform of an environment changed.

    Parameters:

    • scale (float) - The new scale of the environment.

    • translate (list) - The new center point of the environment.

  • ENVIRONMENT_SAVED - Indicates that an environment was saved.

    Parameters:

    • OriginaEnvId (unicode) - The original ID of the environment in the scene that was saved.

    • nweEnvId (unicode) - The ID of the environment in the scene that was saved.

    • newLibraryPath (unicode) - The new library path for the environment.

  • ENVIRONMENT_THUMBNAIL_SAVED - Indicates that the environment thumbnail was saved.

    Parameters:

    • envId (unicode) - The ID of the environment in the scene that was set image

    • newThumbnail (unicode) - The new thumbnail for the environment.