Description Transforms a position vector from one coordinate system to another.
Syntax TransformPosition fromCoord, toCoord, X, Y, Z
Parameters fromCoord As Long Node number of the coordinate system to convert from.
toCoord As Long Node number of the coordinate system to convert to.
X As Double X component of the position vector.
Y As Double Y component of the position vector.
Z As Double Z component of the position vector.
Remarks This subroutine transforms a position vector from one coordinate system to another. If there is a problem, the subroutine sets an error and returns without modifying X,Y, or Z.
If either the fromCoord or toCoord parameter represents the global coordinate system, then use a value of -1
This subroutine modifies the input values of X,Y,Z and outputs the transformed values in X,Y,Z. For example, this script transforms the coordinate position (6,0,3) in the coordinate system of node 4 into a new vector (X,Y,Z) in the global coordinate system.
x=6:y=0:z=3
See Also Examples
|