提交 5389b0c4 编写于 作者: M Martin Wicke

added fromArray and toArray to Matrix3

上级 24cfa675
......@@ -148,7 +148,7 @@ THREE.Matrix3.prototype = {
if ( throwOnInvertible || false ) {
throw new Error( msg );
throw new Error( msg );
} else {
......@@ -208,6 +208,26 @@ THREE.Matrix3.prototype = {
},
fromArray: function ( array ) {
this.elements.set( array );
return this;
},
toArray: function () {
var te = this.elements;
return [
te[ 0 ], te[ 1 ], te[ 2 ],
te[ 3 ], te[ 4 ], te[ 5 ],
te[ 6 ], te[ 7 ], te[ 8 ]
];
},
clone: function () {
var te = this.elements;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册