MCPcopy
hub / github.com/spritejs/spritejs / create

Function create

docs/demo/spritejs.es.js:383–394  ·  view source on GitHub ↗

* Creates a new identity mat2 * * @returns {mat2} a new 2x2 matrix

()

Source from the content-addressed store, hash-verified

381 */
382
383function create() {
384 var out = new _common_js__WEBPACK_IMPORTED_MODULE_0__["ARRAY_TYPE"](4);
385
386 if (_common_js__WEBPACK_IMPORTED_MODULE_0__["ARRAY_TYPE"] != Float32Array) {
387 out[1] = 0;
388 out[2] = 0;
389 }
390
391 out[0] = 1;
392 out[3] = 1;
393 return out;
394}
395/**
396 * Creates a new mat2 initialized with values from an existing matrix
397 *

Callers 1

spritejs.es.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected