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

 

 


SW_getAttributeValue

A library function which retrieves a value from SAA object SAA_AttributeValue.   The SAA_AttributeValue object  is a union with a field specifying how  the data should be accessed (as an integer, as a float, etc). SW_getAttributeValue use this specification field to retrieve the value correctly.

package require SW

SW_getAttributeValue AttributeValueID

AttributeValueID
SAA object SAA_AttributeValue.

Return Value

Procedure returns value currently stored by SAA_AttributeValue object .

Example

Allocate and retrieve current scene, convert model's name "sphere1" to elementID, allocate object SAA_AttributeValue and retrieve value of X translation in local coordinate system for sphere1  ( 139 is track ID for X translation). Retrieve value currently stored by SAA_AttributeValue object, which is the actual value of  X translation for sphere1

set curSceneID [SAA_AllocScene]
Scene1
SAA_sceneGetCurrent $curSceneID
set elementID [SW_name2Element sphere1 $curSceneID]
Elem2
set trnXID [SAA_AllocAttributeValue]
AttributeValue3
SAA_elementGetAttribute $curSceneID $elementID 139 $trnXID
SW_getAttributeValue $trnXID
1.00123

 

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.