public final class MotionLibrary extends AssetLibrary<ReaderSettings,AsyncMotion>
AsyncMotion.entries| Constructor and Description |
|---|
MotionLibrary() |
MotionLibrary(boolean concurrent) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(ReaderSettings assetKey,
AsyncMotion asset)
Add an asset to the library.
|
void |
destroy()
Destroy all models from this
MotionLibrary |
void |
destroy(AsyncMotion asyncMotion)
Destroy the specified motion from this
MotionLibrary |
AsyncMotion |
getOrCreate(AssetManager assets,
ReaderSettings readerSettings,
java.util.function.Consumer<AsyncMotion> initializer) |
void |
onContextLost() |
AsyncMotion |
remove(java.lang.String id) |
assets, clear, contains, get, getKey, getOrCreate, iterator, remove, removeValue, sizepublic MotionLibrary()
public MotionLibrary(boolean concurrent)
public void add(ReaderSettings assetKey, AsyncMotion asset) throws java.lang.IllegalArgumentException
AssetLibraryadd in class AssetLibrary<ReaderSettings,AsyncMotion>assetKey - asset key, usually the loading informationasset - asset to store in the libraryjava.lang.IllegalArgumentException - when the asset is already in the librarypublic AsyncMotion getOrCreate(AssetManager assets, ReaderSettings readerSettings, java.util.function.Consumer<AsyncMotion> initializer)
id - name identifier for the keypublic AsyncMotion remove(java.lang.String id)
id - name of the asset to removepublic void destroy()
MotionLibrarypublic void destroy(AsyncMotion asyncMotion)
MotionLibrarypublic final void onContextLost()
Bonzai Engine 1.4.1-20200831 - A Java OpenGL engine and tools for Windows/Mac/Linux/Android
Copyright © 2007-2019 Jérôme Jouvie bonzaiengine.com contact@bonzaiengine.com