Difference between revisions of "API Panel.Position.RotateAlong"
(XML import of API auto-gen) |
(XML import) |
||
(17 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
− | <sidebar>API | + | <sidebar>API Contents</sidebar> |
Rotates the object by the given rotation along an axis | Rotates the object by the given rotation along an axis | ||
+ | <div style="width:25%; float:right" class="toc"> | ||
+ | ====Class hierarchy==== | ||
+ | [[API Panel|Panel]] | ||
+ | :[[API Panel.Position|Position]] | ||
+ | ::[[API Panel.Position|RotateAlong]] | ||
+ | </div> | ||
+ | __TOC__ | ||
− | + | ==Parameters== | |
− | + | [[Variable Types|HANDLE]] ''Handle'' | |
:The position or component to update | :The position or component to update | ||
:''The default value for this parameter is: '''''this''' | :''The default value for this parameter is: '''''this''' | ||
− | + | [[Variable Types|HANDLE]] ''Pivot'' | |
:The coordinates of the rotation center | :The coordinates of the rotation center | ||
− | + | [[Variable Types|HANDLE]] ''Axis'' | |
:An axis to align the angles to | :An axis to align the angles to | ||
− | + | [[Variable Types|FLOAT]] ''X_Pitch'' | |
:The local X degrees to increment by | :The local X degrees to increment by | ||
:''The default value for this parameter is: '''''0''' | :''The default value for this parameter is: '''''0''' | ||
− | + | [[Variable Types|FLOAT]] ''Y_Yaw'' | |
:The local Y degrees to increment by | :The local Y degrees to increment by | ||
:''The default value for this parameter is: '''''0''' | :''The default value for this parameter is: '''''0''' | ||
− | + | [[Variable Types|FLOAT]] ''Z_Roll'' | |
:The local Z degrees to increment by | :The local Z degrees to increment by | ||
:''The default value for this parameter is: '''''0''' | :''The default value for this parameter is: '''''0''' | ||
− | + | ||
+ | ==Return value== | ||
''This call does not return a value'' | ''This call does not return a value'' | ||
− | |||
− | |||
− | ===Examples | + | ==Detailed description== |
− | + | [[File:SIMAPI_Panel_Position_Rotate_Pic1.png|thumb|200px|right|Rotation around X]] | |
− | * Add to a calculation icon: <pre class="brush:[ | + | The rotation calls allow an object to be [[Object Rotation|rotated]] around any point in any axis. |
+ | |||
+ | The ''Handle'' must be a valid handle to a component or [[Object Position|position]], or a quoted (string) name of an object that can be selected on the panel. | ||
+ | |||
+ | An object can rotate around it's own '''axis''', or around the axis of another object's axis(x,y,x). An axis is the direction an object is facing. | ||
+ | |||
+ | The ''Pivot'' is a component or position to rotate around. The object will adjust its angle as though it is sliding around the edge of a circle, so at 180 degrees the object will appear 'upside-down' in the same way as a human walking around the globe from the north to south pole. | ||
+ | |||
+ | If the ''Pivot'' is zero the object rotates around its own center. | ||
+ | |||
+ | The ''Axis'' is the alignment to rotate around. Specifying zero will cause the object to rotate around its own axis, or this may be the handle of another component or position. | ||
+ | |||
+ | |||
+ | ==Examples== | ||
+ | ===Calling in a calculation=== | ||
+ | * Add to a calculation icon: <pre class="brush:[cpp]">::Panel.Position.RotateAlong(handle, pivot, axis, x_pitch, y_yaw, z_roll)</pre> | ||
+ | |||
+ | ''<span style="color:red;">No additional examples</span>'' |
Latest revision as of 15:57, 16 January 2014
<sidebar>API Contents</sidebar> Rotates the object by the given rotation along an axis
Contents
Parameters
HANDLE Handle
- The position or component to update
- The default value for this parameter is: this
HANDLE Pivot
- The coordinates of the rotation center
HANDLE Axis
- An axis to align the angles to
FLOAT X_Pitch
- The local X degrees to increment by
- The default value for this parameter is: 0
FLOAT Y_Yaw
- The local Y degrees to increment by
- The default value for this parameter is: 0
FLOAT Z_Roll
- The local Z degrees to increment by
- The default value for this parameter is: 0
Return value
This call does not return a value
Detailed description
The rotation calls allow an object to be rotated around any point in any axis.
The Handle must be a valid handle to a component or position, or a quoted (string) name of an object that can be selected on the panel.
An object can rotate around it's own axis, or around the axis of another object's axis(x,y,x). An axis is the direction an object is facing.
The Pivot is a component or position to rotate around. The object will adjust its angle as though it is sliding around the edge of a circle, so at 180 degrees the object will appear 'upside-down' in the same way as a human walking around the globe from the north to south pole.
If the Pivot is zero the object rotates around its own center.
The Axis is the alignment to rotate around. Specifying zero will cause the object to rotate around its own axis, or this may be the handle of another component or position.
Examples
Calling in a calculation
- Add to a calculation icon:
::Panel.Position.RotateAlong(handle, pivot, axis, x_pitch, y_yaw, z_roll)
No additional examples