This PR introduces a standardised format for model loaders. This avoids users having to rely on format-specific asset types, instead generifying the asset type to a core Trial class. The interface and resulting data from loading a model file is also standardised with it.
New introductions are:
model class, which encapsulates all the data a model can load: materials, meshes, animation clips, a skeleton, and scene trees
model-loader resource-generator, which will simply call out to load-model to load the input file and produce the model instance
model-file asset, a thin combination of asset and model-loader
load-model and save-model analogues to load-image and save-image. Since model loading is more complex, the load function takes a generator argument to use for resource registration.
Existing formats must be rewritten to remove the format-specific asset types, and trial-assets must be updated to remove the specific systems and types.
This PR introduces a standardised format for model loaders. This avoids users having to rely on format-specific asset types, instead generifying the asset type to a core Trial class. The interface and resulting data from loading a model file is also standardised with it.
New introductions are:
model
class, which encapsulates all the data a model can load: materials, meshes, animation clips, a skeleton, and scene treesmodel-loader
resource-generator, which will simply call out toload-model
to load the input file and produce themodel
instancemodel-file
asset, a thin combination ofasset
andmodel-loader
load-model
andsave-model
analogues toload-image
andsave-image
. Since model loading is more complex, the load function takes agenerator
argument to use for resource registration.Existing formats must be rewritten to remove the format-specific asset types, and
trial-assets
must be updated to remove the specific systems and types.