createInstance

Adds a new instance to the asset.

Use this with caution. It is more efficient to pre-allocate a max number of instances, and gradually add them to the scene as needed. Instances can also be "recycled" by removing and re-adding them to the scene.

NOTE: destroyInstance() does not exist because gltfio favors flat arrays for storage of entity lists and instance lists, which would be slow to shift. We also wish to discourage create/destroy churn, as noted above.

This cannot be called after FilamentAsset#releaseSourceData(). Animation is not supported in new instances.

See also

AssetLoader.createInstance