GetRelativeValue

Description

Returns the relative values at the specified index from the interpolator-driven parameter.

Scripting Syntax

    GetRelativeValue( InputObj, Index )

Parameters

Parameter | Type | Description
InputObj | String | Animated parameter(s) that the interpolator is controlling or the interpolator itself Default Value: Currently selected and marked parameter
Index | Integer | Index of the relative value to get. Default Value: 0 Possible Values: • 0<Index<NbRelativeValues: Keys are indexed from 0 to (NbRelativeValues - 1)

Return Value

Returns an Array containing the relative values for each parameter.

Examples

VBScript Example

    NewScene
    CreatePrim "Cone", "MeshSurface"
    CreatePrim "Cube", "MeshSurface"
    SetExpr "cube.kine.local.posx", "l_interp( cone.kine.global.posx, cone.kine.global.posy )"
    SelectObj "cone", , True
    SetValue "cone.kine.local.posx", 1
    SetValue "cone.kine.local.posy", 1
    SetValue "cube.kine.local.posx", 1
    SetRelativeValues "cube.kine.local.posx"
    SetValue "cone.kine.local.posx", 2
    SetValue "cone.kine.local.posy", 2
    SetValue "cube.kine.local.posx", 2
    SetRelativeValues "cube.kine.local.posx"
    values = GetRelativeValue( "cube.kine.local.Expression.Interpolator", 1)
    i = 0
    for each item in values
       if (i = 0) then
           logmessage "Controlled = "  & item
       else
           logmessage "controlling #" & i & " = " & item
       end if
       i = i + 1
    next
    'INFO : "Controlled = 2"
    'INFO : "controlling #1 = 2"
    'INFO : "controlling #2 = 2"

See Also

GetNumRelativeValues | RemoveRelativeValue

Autodesk Softimage v7.5