Description
Evaluate the curve position, tangency, and normal at a given length or ratio.
Note: This command uses output arguments. C# and some scripting languages (such as JScript, PerlScript and Python) don't support arguments passed by reference so you need to use the best workaround for your situation:
For scripting languages this command returns an ISIVTCollection which you can use to get the output arguments.
For C# you can use the XSIApplication.ExecuteCommand method to call this command. ExecuteCommand packs the output arguments into a C# System.Object containing an Array of the output arguments (see Calling Commands from C#).
Scripting Syntax
EvaluateCurveAt( InputObj, Value, [Local], [PosX], [PosY], [PosZ], [TanX], [TanY], [TanZ], [NorX], [NorY], [NorZ] )
Parameters
|
Parameter |
Type |
Description |
|
InputObj |
Curve to evaluate. |
|
|
Value |
A percentage or a length, depending on the value of the Percentage parameter. |
|
|
Local |
True to evaluate at a certain percentage along the curve, False to evaluate at a specific length. Default Value: False |
|
|
PosX [out] |
Returns the X component of the postion of the evaluated point |
|
|
PosY [out] |
Returns the Y component of the Postion of the evaluated point |
|
|
PosZ [out] |
Returns the Z component of the Postion of the evaluated point |
|
|
TanX [out] |
Returns the X component of the Tangent of the evaluated point |
|
|
TanY [out] |
Returns the Y component of the Tangent of the evaluated point |
|
|
TanZ [out] |
Returns the Z component of the Tangent of the evaluated point |
|
|
NorX [out] |
Returns the X component of the Normal of the evaluated point |
|
|
NorY [out] |
Returns the Y component of the Normal of the evaluated point |
|
|
NorZ [out] |
Returns the Z component of the Normal of the evaluated point |
Examples
VBScript Example
'This example shows how to evaluate a curve by percentage. newscene dim posx, posy, posz, tanx, tany, tanz, normx, normy, normz CreatePrim "Spiral", "NurbsCurve" ' Evaluate at a point 50% along the curve length set rtn = EvaluateCurveAt( "Spiral", .5, True, posx, posy, posz, tanx, tany, tanz, normx, normy, normz ) logmessage "Position : ("& posx & ", " & posy & ", " & posz & ")" logmessage "tangent : ("& tanx & ", " & tany & ", " & tanz & ")" logmessage "Normal : ("& normx & ", " & normy & ", " & normz & ")"
See Also
|
|
Autodesk Softimage v7.5