file: Model3D.aus

class: Model3D

[25:7] extends: FxObj

Model3D loads a 3D model file into a JavaFX 3D scene graph. It wraps the FXyz3D importer library (org.fxyz3d.importers), which reads OBJ (.obj), Maya (.ma), and JavaFX FXML (.fxml) model files. After loading, getRoot() returns the model as a JavaFX Group you add to your scene, SubScene, or another parent. This is the JavaFX-specific model-import entry point for Aussom. Support for more formats (such as glTF) can be added to this same class later without changing how callers load and use a model. The JavaFX toolkit must be running before a model is loaded, because the importer builds live JavaFX nodes. Use it from an fx app (or after the toolkit has started).

Methods