loadGLTFModel method
Loads a GLTF model from the specified path and adds it to the scene.
Implementation
@override
Future<void> loadGLTFModel(String path) async {
try {
dynamic model = await loaderController.loadModel(path);
model.scale.set(0.5, 0.5, 0.5);
model.position.z = -1;
sceneController.addElement(model);
rendererController.render(
sceneController.scene, cameraController.perspectiveCamera);
} catch (e) {
throw Exception('Failed to load gltf model');
}
}