Skip to content

Commit

Permalink
Fixed bug in gltf parser
Browse files Browse the repository at this point in the history
  • Loading branch information
jnsmalm committed Jun 30, 2020
1 parent 1f73d15 commit 994864b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/gltf/gltf-parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export class glTFParser {
createModel() {
let hierarchy = this.createHierarchy()
let scene = this.descriptor.scene || 0
let model = new Model3D(hierarchy.meshes)
let model = new Model3D()
for (let child of this.descriptor.scenes[scene].nodes) {
this.addChild(model, child, hierarchy.nodes)
}
Expand All @@ -36,6 +36,7 @@ export class glTFParser {
model.animations.push(this.createAnimation(animation, hierarchy.nodes))
}
}
model.meshes = hierarchy.meshes
return model
}

Expand Down

0 comments on commit 994864b

Please sign in to comment.