tiny optimisation

This commit is contained in:
Volodymyr Boichentsov 2019-07-15 17:16:21 +03:00
parent 349582af8d
commit 08b98cdb8a
2 changed files with 3 additions and 2 deletions

2
Draco

@ -1 +1 @@
Subproject commit 0dac933ae63d023d2ba87decb2a5485beac7f548
Subproject commit 10caef92253b10439b3bc560ecef4a79804f612a

View File

@ -195,6 +195,7 @@ extension GLTF {
}
func _constructNodesTree(rootNode:SCNNode, nodes:[Int], group:DispatchGroup, hidden:Bool) {
var cache_nodes = self.cache_nodes
for nodeIndex in nodes {
group.enter()
let scnNode = SCNNode()
@ -214,7 +215,7 @@ extension GLTF {
}
}
rootNode.addChildNode(scnNode)
self.cache_nodes?[nodeIndex] = scnNode
cache_nodes?[nodeIndex] = scnNode
self._preloadBuffersData(nodeIndex: nodeIndex) { error in
if error != nil {