Difference between revisions of "LlRot2Euler"

From Second Life Wiki
Jump to navigation Jump to search
m (changed flag order to effect proper placement in function category)
m (lsl code tagging)
Line 9: Line 9:
|caveats=*Angles greater than PI (180 degrees) are returned as negative angles.
|caveats=*Angles greater than PI (180 degrees) are returned as negative angles.
|constants
|constants
|examples=<pre>
|examples=
<lsl>
default
default
{
{
Line 18: Line 19:
     }
     }
}
}
</pre>
</lsl>
|helpers
|helpers
|also_functions={{LSL DefineRow||[[llEuler2Rot]]|}}
|also_functions={{LSL DefineRow||[[llEuler2Rot]]|}}

Revision as of 14:07, 30 March 2008

Summary

Function: vector llRot2Euler( rotation quat );
0.0 Forced Delay
10.0 Energy

Returns a vector that is the Euler representation (roll, pitch, yaw) of quat.

• rotation quat Any valid rotation

Caveats

  • Angles greater than PI (180 degrees) are returned as negative angles.

Examples

<lsl> default {

   state_entry()
   {
       rotation input = <0.0, 1.0, 0.0, 0.0>;//not advised to make your own quaternion
       llSay(0,"The Rot2Euler of "+(string)input+" is: "+(string)llRot2Euler(input) );
   }

}

</lsl>

See Also

Functions

•  llEuler2Rot

Articles

•  "Wikipedia logo"Euler_Angles

Deep Notes

Signature

function vector llRot2Euler( rotation quat );