aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/3D/StageLine.js
diff options
context:
space:
mode:
authorValerio Virgillito2012-03-06 10:58:25 -0800
committerValerio Virgillito2012-03-06 10:58:25 -0800
commit84332ab81c1b445195f1d9be8bbeae0725c8e758 (patch)
treee322baa1f98d4507ec255279198fa2284b2dff3c /js/helper-classes/3D/StageLine.js
parent13f52cf0c74f53a919fa864f86669e8155f82961 (diff)
downloadninja-84332ab81c1b445195f1d9be8bbeae0725c8e758.tar.gz
Squashed commit of preload-fix into Master
- Requiring all the previously pre-loaded files - RDGE, Codemirror and gl-matrix are not included via a script tag. Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/helper-classes/3D/StageLine.js')
-rwxr-xr-xjs/helper-classes/3D/StageLine.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/js/helper-classes/3D/StageLine.js b/js/helper-classes/3D/StageLine.js
index e0e7a8e3..b86673d1 100755
--- a/js/helper-classes/3D/StageLine.js
+++ b/js/helper-classes/3D/StageLine.js
@@ -149,8 +149,8 @@ var StageLine = exports.StageLine = Object.create(Object.prototype, {
149 var vec = vecUtils.vecSubtract(3, bPt1, bPt0); 149 var vec = vecUtils.vecSubtract(3, bPt1, bPt0);
150 if (plane.isBackFacing()) 150 if (plane.isBackFacing())
151 MathUtils.negate( vec ); 151 MathUtils.negate( vec );
152 planeEq = Vector.create( [-vec[1], vec[0], 0] ); 152 planeEq = [-vec[1], vec[0], 0];
153 var normal = Vector.create( [planeEq[0], planeEq[1], planeEq[2]] ); 153 var normal = [planeEq[0], planeEq[1], planeEq[2]];
154// var d = -planeEq.dot(bPt0); 154// var d = -planeEq.dot(bPt0);
155 var d = -vecUtils.vecDot(3, planeEq, bPt0); 155 var d = -vecUtils.vecDot(3, planeEq, bPt0);
156 planeEq[3] = d; 156 planeEq[3] = d;
@@ -414,8 +414,8 @@ var StageLine = exports.StageLine = Object.create(Object.prototype, {
414 if (pt0[1] < pt1[1]) { yMin = pt0[1]; yMax = pt1[1]; } else { yMin = pt1[1]; yMax = pt0[1]; } 414 if (pt0[1] < pt1[1]) { yMin = pt0[1]; yMax = pt1[1]; } else { yMin = pt1[1]; yMax = pt0[1]; }
415 if (pt0[2] < pt1[2]) { zMin = pt0[2]; zMax = pt1[2]; } else { zMin = pt1[2]; zMax = pt0[2]; } 415 if (pt0[2] < pt1[2]) { zMin = pt0[2]; zMax = pt1[2]; } else { zMin = pt1[2]; zMax = pt0[2]; }
416 416
417 this._minPt = Vector.create( [xMin, yMin, zMin] ); 417 this._minPt = [xMin, yMin, zMin];
418 this._maxPt = Vector.create( [xMax, yMax, zMax] ); 418 this._maxPt = [xMax, yMax, zMax];
419 } 419 }
420 }//, 420 }//,
421 421