diff options
author | Jon Reid | 2012-04-10 14:52:23 -0700 |
---|---|---|
committer | Jon Reid | 2012-04-10 14:52:23 -0700 |
commit | c19987997758cf47ac9b93a2a767a0e2a9072745 (patch) | |
tree | eb68491c5d04a5cf5ab75bedf2d6bbed3c7a3603 /js/helper-classes/3D/view-utils.js | |
parent | 03a3b32b9b0fd2dc8e4b54bfd5282fd1f8fb6ed6 (diff) | |
parent | 422b14fc60be84c116115f2e71e3499e232f3f05 (diff) | |
download | ninja-c19987997758cf47ac9b93a2a767a0e2a9072745.tar.gz |
Merge remote-tracking branch 'ninja-jduran/TimelineUber' into timeline-local
Diffstat (limited to 'js/helper-classes/3D/view-utils.js')
-rwxr-xr-x | js/helper-classes/3D/view-utils.js | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/js/helper-classes/3D/view-utils.js b/js/helper-classes/3D/view-utils.js index a72b7906..63c2cb52 100755 --- a/js/helper-classes/3D/view-utils.js +++ b/js/helper-classes/3D/view-utils.js | |||
@@ -1099,54 +1099,6 @@ exports.ViewUtils = Montage.create(Component, { | |||
1099 | } | 1099 | } |
1100 | }, | 1100 | }, |
1101 | 1101 | ||
1102 | transformStringToMat: { | ||
1103 | value: function( str ) { | ||
1104 | var rtnMat; | ||
1105 | |||
1106 | var index1 = str.indexOf( "matrix3d("); | ||
1107 | if (index1 >= 0) | ||
1108 | { | ||
1109 | index1 += 9; // do not include 'matrix3d(' | ||
1110 | var index2 = str.indexOf( ")", index1 ); | ||
1111 | if (index2 >= 0) | ||
1112 | { | ||
1113 | var substr = str.substr( index1, (index2-index1)); | ||
1114 | if (substr && (substr.length > 0)) | ||
1115 | { | ||
1116 | var numArray = substr.split(','); | ||
1117 | var nNums = numArray.length; | ||
1118 | if (nNums == 16) | ||
1119 | { | ||
1120 | // gl-matrix wants row order | ||
1121 | rtnMat = numArray; | ||
1122 | for (var i=0; i<16; i++) | ||
1123 | rtnMat[i] = Number( rtnMat[i] ); | ||
1124 | |||
1125 | // the matrix as input is column major order. The Matrix | ||
1126 | // class expects the numbers in row major order. | ||
1127 | /* | ||
1128 | var rowArray = new Array; | ||
1129 | for (var i=0; i<4; i++) | ||
1130 | { | ||
1131 | rtnMat.push( numArray[i] ); | ||
1132 | var row = new Array; | ||
1133 | row.push( Number(numArray[i ]) ); | ||
1134 | row.push( Number(numArray[i+ 4]) ); | ||
1135 | row.push( Number(numArray[i+ 8]) ); | ||
1136 | row.push( Number(numArray[i+12]) ); | ||
1137 | rowArray.push( row ); | ||
1138 | } | ||
1139 | rtnMat = Matrix.create( rowArray ); | ||
1140 | */ | ||
1141 | } | ||
1142 | } | ||
1143 | } | ||
1144 | } | ||
1145 | |||
1146 | return rtnMat; | ||
1147 | } | ||
1148 | }, | ||
1149 | |||
1150 | pushViewportObj: { | 1102 | pushViewportObj: { |
1151 | value: function( obj ) { | 1103 | value: function( obj ) { |
1152 | this._viewportObjStack.push( this.m_viewportObj ); | 1104 | this._viewportObjStack.push( this.m_viewportObj ); |