提交 b27fa8e6 编写于 作者: M Mr.doob

Docs: Projector.

上级 51db1370
......@@ -112,7 +112,7 @@ Example: rgb(r, g, b)
<h3>.clone() [page:Color]</h3>
<div>
Clones this object.
Clones this color.
</div>
<h2>Source</h2>
......
......@@ -297,6 +297,11 @@ Rotates this matrix around z axis by *angle*.
Translates this matrix by vector *v*.
</div>
<h3>.clone() [page:Matrix4]</h3>
<div>
Clones this matrix.
</div>
<h2>Static Methods</h2>
......
<h1>[name]</h1>
<div class="desc">Projecting points between spaces.</div>
<div class="desc">Projects points between spaces.</div>
<h2>Constructor</h2>
......@@ -8,18 +8,21 @@
<h3>[name]()</h3>
<h2>Properties</h2>
<h3>.[page:Vector3 todo]</h3>
<h2>Methods</h2>
<h3>.projectVector( [page:Vector3 vector], [page:Camera camera] ) [page:Vector3]</h3>
<h2>Methods</h2>
<h3>.unprojectVector( [page:Vector3 vector], [page:Camera camera] ) [page:Vector3]</h3>
<h3>.projectVector( [page:Vector3 todo] )</h3>
<h3>.pickingRay( [page:Vector3 vector], [page:Camera camera] ) [page:Ray]</h3>
<div>
todo — todo<br />
Translates a 2D point from NDC to a [page:Ray] that can be used for picking.
</div>
<h3>.projectGraph( [page:Object3D root], [page:Boolean sort] ) [page:Object]</h3>
<h3>.projectScene( [page:Scene scene], [page:Camera camera], [page:Boolean sort] ) [page:Object]</h3>
<h2>Source</h2>
......
<h1>[name]</h1>
<div class="desc">todo</div>
<div class="desc">Implementation of a quaternion</div>
<h2>Constructor</h2>
<h3>[name]()</h3>
<h3>[name]( [page:Number x], [page:Number y], [page:Number z], [page:Number w] )</h3>
<h2>Properties</h2>
<h3>.[page:Vector3 todo]</h3>
<h3>.[page:Number x]</h3>
<h3>.[page:Number y]</h3>
<h3>.[page:Number z]</h3>
<h3>.[page:Number w]</h3>
<h2>Methods</h2>
<h3>.todo( [page:Vector3 todo] )</h3>
<h3>.copy( q ) [page:Quaternion]</h3>
<div>
Copies value of *q* to this quaternion.
</div>
<h3>.clone() [page:Quaternion]</h3>
<div>
todo — todo<br />
Clones this quaternion.
</div>
......
......@@ -280,19 +280,6 @@ THREE.Matrix4.prototype = {
},
clone: function () {
var m = new THREE.Matrix4();
m.n11 = this.n11; m.n12 = this.n12; m.n13 = this.n13; m.n14 = this.n14;
m.n21 = this.n21; m.n22 = this.n22; m.n23 = this.n23; m.n24 = this.n24;
m.n31 = this.n31; m.n32 = this.n32; m.n33 = this.n33; m.n34 = this.n34;
m.n41 = this.n41; m.n42 = this.n42; m.n43 = this.n43; m.n44 = this.n44;
return m;
},
flattenToArray: function ( flat ) {
flat[ 0 ] = this.n11; flat[ 1 ] = this.n21; flat[ 2 ] = this.n31; flat[ 3 ] = this.n41;
......@@ -934,6 +921,17 @@ THREE.Matrix4.prototype = {
return this;
},
clone: function () {
return new THREE.Matrix4(
this.n11, this.n12, this.n13, this.n14,
this.n21, this.n22, this.n23, this.n24,
this.n31, this.n32, this.n33, this.n34,
this.n41, this.n42, this.n43, this.n44
);
}
};
......
......@@ -49,12 +49,6 @@ THREE.Projector = function() {
};
/**
* Translates a 2D point from NDC to a THREE.Ray
* that can be used for picking.
* @vector - THREE.Vector3 that represents 2D point
* @camera - THREE.Camera
*/
this.pickingRay = function ( vector, camera ) {
var end, ray, t;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册