vcanim.gif (8357 bytes)SW_name2Element
Home ] Sales ] Products ] Services ] Support ] Downloads ]

 

 


SW_name2Element

Retrieves a corresponding element ID for a given element name.

package require SW_library

SW_name2Element elementName [sceneID]

elementName
A Softimage element name without the prefix.
sceneID
Optional parameter. If the scene ID is omitted then the current scene is assumed.

Return Value

If the procedure succeeds then it returns an element ID. If there is no element with the given name then the procedure returns nothing. If an error occurs then an error message string is returned on the TK console command line.

Example

set curSceneID [SAA_AllocScene]
Scene2
SAA_sceneGetCurrent $curSceneID
set elementID [SW_name2Element sphere1 $curSceneID]
Elem4
SAA_elemetGetBoundingBox $curSceneID $elementID minX minY minZ maxX maxY maxZ

This example allocates and retrieves the current scene, retrieves the element ID corresponding to the name sphere1, and then retrieves BoundingBox attribute.


Behaviors Overview ] Behavior Evaluate ] Behavior Edit ] Debugger ] Console ] Find ] SAA Library ] SW library ] SWC library ] SWN library index ] SWU library ] Attributes Index ] Scripting Examples ]

copyright Video-Collage Inc.