source: other-projects/playing-in-the-street/summer-2013/trunk/Playing-in-the-Street-WPF/Content/Web/mrdoob-three.js-4862f5f/docs/api/math/Euler.html@ 28897

Last change on this file since 28897 was 28897, checked in by davidb, 10 years ago

GUI front-end to server base plus web page content

File size: 3.9 KB
Line 
1<!DOCTYPE html>
2<html lang="en">
3 <head>
4 <meta charset="utf-8" />
5 <script src="../../list.js"></script>
6 <script src="../../page.js"></script>
7 <link type="text/css" rel="stylesheet" href="../../page.css" />
8 </head>
9 <body>
10 <h1>[name]</h1>
11
12 <div class="desc">Euler Angles. <br/><br/>
13
14 Euler angles describe a rotation transformation by rotating an object on its various axes in specified amounts per axis, and a specified axis order.
15 (More information on <a href='http://en.wikipedia.org/wiki/Euler_angles' target='blank'>Wikipedia</a>)</div>
16
17 <h2>Example</h2>
18
19 <code>var a = new THREE.Euler( 0, 1, 1.57, 'XYZ' );
20 var b = new THREE.Vector3( 1, 0, 1 );
21 b.applyEuler(a);
22 </code>
23
24
25 <h2>Constructor</h2>
26
27
28 <h3>[name]( [page:Float x], [page:Float y], [page:Float z], [page:String order] )</h3>
29 <div>
30 x -- [page:Float] the angle of the x axis in radians<br />
31 y -- [page:Float] the angle of the y axis in radians<br />
32 z -- [page:Float] the angle of the z axis in radians<br />
33 order -- [page:String] A string representing the order that the rotations are applied, defaults to 'XYZ' (must be upper case).
34 </div>
35 <div>
36 A euler angle for transforming
37 </div>
38
39
40 <h2>Properties</h2>
41
42 <h3>.[page:Float x]</h3>
43
44 <h3>.[page:Float y]</h3>
45
46 <h3>.[page:Float z]</h3>
47
48 <h3>.[page:String order]</h3>
49
50
51
52 <h2>Methods</h2>
53
54 <h3>.set( [page:Float x], [page:Float y], [page:Float z], [page:String order] ) [page:Euler this]</h3>
55 <div>
56 x -- [page:Float] Angle in x axis in radians<br />
57 x -- [page:Float] Angle in x axis in radians<br />
58 x -- [page:Float] Angle in x axis in radians<br />
59 order -- [page:string] Order of axes, defaults to 'XYZ' (must be upper case)
60 </div>
61 <div>
62 Sets the angles of this euler transform.
63 </div>
64
65 <h3>.copy( [page:Euler euler] ) [page:Euler this]</h3>
66 <div>
67 Copies value of *euler* to this euler.
68 </div>
69
70 <h3>.setFromRotationMatrix( [page:Matrix4 m], [page:String order] ) [page:Euler this]</h3>
71 <div>
72 m -- [page:Matrix4] assumes upper 3x3 of matrix is a pure rotation matrix (i.e. unscaled)<br />
73 order -- [page:string] Order of axes, defaults to 'XYZ' (must be upper case)
74 </div>
75 <div>
76 Sets the angles of this euler transform from a pure rotation matrix based on the orientation specified by order.
77 </div>
78
79 <h3>.setFromQuaternion( [page:Quaternion q], [page:String order] ) [page:Euler this]</h3>
80 <div>
81 q -- [page:Quaternion] quaternion must be normalized<br />
82 order -- [page:string] Order of axes, defaults to 'XYZ' (must be upper case)
83 </div>
84 <div>
85 Sets the angles of this euler transform from a normalized quaternion based on the orientation specified by order.
86 </div>
87
88 <h3>.reorder( [page:String newOrder] ) [page:Euler this]</h3>
89 <div>
90 Resets the euler angle with a new order by creating a quaternion from this euler angle and then setting this euler angle with the quaternion and the new order. <br />
91 WARNING: this discards revolution information.
92 </div>
93
94 <h3>.fromArray([page:Array array]) [page:Euler this]</h3>
95 <div>
96 array -- [page:Array] of length 3 or 4. array[3] is an optional order argument.
97 </div>
98 <div>
99 Assigns this euler's x angle to array[0]. <br />
100 Assigns this euler's y angle to array[1]. <br />
101 Assigns this euler's z angle to array[2]. <br />
102 Optionally assigns this euler's order to array[3].
103 </div>
104
105 <h3>.toArray() [page:Array]</h3>
106 <div>
107 Returns an array [x, y, z, order].
108 </div>
109
110 <h3>.equals( [page:Euler euler] ) [page:Boolean]</h3>
111 <div>
112 Checks for strict equality of this euler and *euler*.
113 </div>
114
115 <h3>.clone() [page:Euler]</h3>
116 <div>
117 Returns a new euler created from this euler.
118 </div>
119
120
121
122
123 <h2>Source</h2>
124
125 [link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]
126 </body>
127</html>
Note: See TracBrowser for help on using the repository browser.