Comparing version 0.0.102 to 0.0.103
{ | ||
"name": "ogl", | ||
"version": "0.0.102", | ||
"version": "0.0.103", | ||
"description": "WebGL Library", | ||
@@ -5,0 +5,0 @@ "exports": "./src/index.mjs", |
@@ -786,2 +786,3 @@ import { Geometry } from '../core/Geometry.js'; | ||
const joint = nodes[i]; | ||
joint.skin = skin; | ||
joint.bindInverse = new Mat4(...skin.inverseBindMatrices.data.slice(index * 16, (index + 1) * 16)); | ||
@@ -797,9 +798,12 @@ return joint; | ||
return desc.animations.map( | ||
({ | ||
channels, // required | ||
samplers, // required | ||
name, // optional | ||
// extensions, // optional | ||
// extras, // optional | ||
}) => { | ||
( | ||
{ | ||
channels, // required | ||
samplers, // required | ||
name, // optional | ||
// extensions, // optional | ||
// extras, // optional | ||
}, | ||
animationIndex | ||
) => { | ||
const data = channels.map( | ||
@@ -832,2 +836,6 @@ ({ | ||
// Store reference on node for cyclical retrieval | ||
if (!node.animations) node.animations = []; | ||
if (!node.animations.includes(animationIndex)) node.animations.push(animationIndex); | ||
return { | ||
@@ -834,0 +842,0 @@ node, |
@@ -14,3 +14,3 @@ import { Mesh } from '../core/Mesh.js'; | ||
this.createBoneTexture(); | ||
this.animations = []; | ||
// this.animations = []; | ||
} | ||
@@ -17,0 +17,0 @@ |
329426
9055