SceneViewController class
Controls a SceneView or ARSceneView after creation.
Attach a controller to a scene widget, then call methods on it
after onViewCreated fires:
final controller = SceneViewController();
SceneView(
controller: controller,
onViewCreated: () {
controller.loadModel(ModelNode(modelPath: 'models/helmet.glb'));
},
);
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isAttached → bool
-
Whether this controller is attached to a platform view.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addGeometry(
GeometryNode node) → Future< void> - Add a geometry node (placeholder -- not yet rendered natively).
-
addLight(
LightNode node) → Future< void> - Add a light node (placeholder -- uses scene defaults on native side).
-
attach(
int viewId) → void - Called internally when the platform view is created.
-
clearScene(
) → Future< void> - Clear all nodes from the scene.
-
dispose(
) → void - Called internally when the platform view is disposed.
-
loadModel(
ModelNode node) → Future< void> - Load a glTF/GLB model into the scene.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setEnvironment(
String hdrPath) → Future< void> - Set the environment HDR for image-based lighting.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited