diff options
author | Nivesh Rajbhandari | 2012-03-12 16:25:28 -0700 |
---|---|---|
committer | Nivesh Rajbhandari | 2012-03-12 16:25:28 -0700 |
commit | 5fb358d9e80a364d5f300d60b7a9fe0f773741e7 (patch) | |
tree | 2c4d5292b19c91697dffb542f369ec9dcb340f77 /js/helper-classes/3D/view-utils.js | |
parent | 5f9b67be3b8bdb391d021103c6bcee6be2f6cdf4 (diff) | |
parent | 69d90467865a1384725b2301901be2180c5a841f (diff) | |
download | ninja-5fb358d9e80a364d5f300d60b7a9fe0f773741e7.tar.gz |
Merge branch 'refs/heads/ninja-internal' into ToolFixes
Diffstat (limited to 'js/helper-classes/3D/view-utils.js')
-rwxr-xr-x | js/helper-classes/3D/view-utils.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/js/helper-classes/3D/view-utils.js b/js/helper-classes/3D/view-utils.js index c1f59397..5a820fc2 100755 --- a/js/helper-classes/3D/view-utils.js +++ b/js/helper-classes/3D/view-utils.js | |||
@@ -214,7 +214,7 @@ exports.ViewUtils = Montage.create(Component, { | |||
214 | { | 214 | { |
215 | var bounds = this.getViewportBounds(); | 215 | var bounds = this.getViewportBounds(); |
216 | cop = bounds.getCenter(); | 216 | cop = bounds.getCenter(); |
217 | //cop = Vector.create( [bounds.getRight(), bounds.getBottom()] ); | 217 | //cop = [bounds.getRight(), bounds.getBottom()]; |
218 | } | 218 | } |
219 | 219 | ||
220 | return cop; | 220 | return cop; |
@@ -547,8 +547,8 @@ exports.ViewUtils = Montage.create(Component, { | |||
547 | pt = this.screenToView( pt[0], pt[1], pt[2] ); | 547 | pt = this.screenToView( pt[0], pt[1], pt[2] ); |
548 | 548 | ||
549 | var eyePt = this.getEyePoint(); | 549 | var eyePt = this.getEyePoint(); |
550 | //var eyePt = Vector.create( [0, 0, 0] ); | 550 | //var eyePt = [0, 0, 0]; |
551 | //var vec = Vector.create( [pt[0], pt[1], pt[2]] ).subtract( eyePt ); | 551 | //var vec = [pt[0], pt[1], pt[2]].subtract( eyePt ); |
552 | var vec = vecUtils.vecSubtract(3, [pt[0], pt[1], pt[2]], eyePt); | 552 | var vec = vecUtils.vecSubtract(3, [pt[0], pt[1], pt[2]], eyePt); |
553 | vec = vecUtils.vecNormalize( 3, vec ); | 553 | vec = vecUtils.vecNormalize( 3, vec ); |
554 | 554 | ||
@@ -1251,9 +1251,9 @@ exports.ViewUtils = Montage.create(Component, { | |||
1251 | // the input zoomFactor is the total zoom for the resulting matrix, so we need to | 1251 | // the input zoomFactor is the total zoom for the resulting matrix, so we need to |
1252 | // get the current scale from the existing userContent matrix | 1252 | // get the current scale from the existing userContent matrix |
1253 | // we assume a uniform scale. | 1253 | // we assume a uniform scale. |
1254 | var ucX = Vector.create([userContentMat[0], userContentMat[1+0], userContentMat[2+0]]); | 1254 | var ucX = [userContentMat[0], userContentMat[1+0], userContentMat[2+0]]; |
1255 | var ucY = Vector.create([userContentMat[4], userContentMat[1+4], userContentMat[2+4]]); | 1255 | var ucY = [userContentMat[4], userContentMat[1+4], userContentMat[2+4]]; |
1256 | var ucZ = Vector.create([userContentMat[8], userContentMat[1+8], userContentMat[2+8]]); | 1256 | var ucZ = [userContentMat[8], userContentMat[1+8], userContentMat[2+8]]; |
1257 | var sx = vecUtils.vecMag(3, ucX), | 1257 | var sx = vecUtils.vecMag(3, ucX), |
1258 | sy = vecUtils.vecMag(3, ucY), | 1258 | sy = vecUtils.vecMag(3, ucY), |
1259 | sz = vecUtils.vecMag(3, ucZ); | 1259 | sz = vecUtils.vecMag(3, ucZ); |