aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/3D/math-utils.js
diff options
context:
space:
mode:
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 )