aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/3D/math-utils.js
diff options
context:
space:
mode:
authorPushkar Joshi2012-03-05 14:49:05 -0800
committerPushkar Joshi2012-03-05 14:49:05 -0800
commitdb82be91f767a07b7cb8c97ca3d9f4c4d75bc9ae (patch)
tree21e0ee213e24de67eb9c4cddfc5f3069c2257aae /js/helper-classes/3D/math-utils.js
parent4419209a1fd850ab468209b562b66b0242b42a9c (diff)
parent13f52cf0c74f53a919fa864f86669e8155f82961 (diff)
downloadninja-db82be91f767a07b7cb8c97ca3d9f4c4d75bc9ae.tar.gz
Merge branch 'master' into brushtool
Diffstat (limited to 'js/helper-classes/3D/math-utils.js')
-rwxr-xr-xjs/helper-classes/3D/math-utils.js33
1 files changed, 33 insertions, 0 deletions
diff --git a/js/helper-classes/3D/math-utils.js b/js/helper-classes/3D/math-utils.js
index 37044763..de63f880 100755
--- a/js/helper-classes/3D/math-utils.js
+++ b/js/helper-classes/3D/math-utils.js
@@ -538,6 +538,39 @@ var MathUtilsClass = exports.MathUtilsClass = Object.create(Object.prototype, {
538 } 538 }
539 }, 539 },
540 540
541 isIdentityMatrix: {
542 value: function( mat )
543 {
544 if(!mat)
545 {
546 return false;
547 }
548 else
549 {
550 if(mat[0] !== 1) return false;
551 if(mat[1] !== 0) return false;
552 if(mat[2] !== 0) return false;
553 if(mat[3] !== 0) return false;
554
555 if(mat[4] !== 0) return false;
556 if(mat[5] !== 1) return false;
557 if(mat[6] !== 0) return false;
558 if(mat[7] !== 0) return false;
559
560 if(mat[8] !== 0) return false;
561 if(mat[9] !== 0) return false;
562 if(mat[10] !== 1) return false;
563 if(mat[11] !== 0) return false;
564
565 if(mat[12] !== 0) return false;
566 if(mat[13] !== 0) return false;
567 if(mat[14] !== 0) return false;
568 if(mat[15] !== 1) return false;
569 }
570 return true;
571 }
572 },
573
541 rectsOverlap: 574 rectsOverlap:
542 { 575 {
543 value: function( pt, width, height, elt ) 576 value: function( pt, width, height, elt )