Flutter plugin for SceneView — 3D and AR scenes using native renderers.
| Platform | Renderer | Status |
|---|---|---|
| Android | Filament (via Jetpack Compose) | Alpha — 3D model loading works |
| iOS | RealityKit (via SceneViewSwift) | Alpha — 3D model loading works |
- Load and display 3D models (GLB/GLTF) using native renderers
- AR scenes with plane detection on Android (ARCore) and iOS (ARKit)
- HDR environment lighting
- Orbit camera controls (touch gestures)
SceneViewControllerfor imperative commands- Geometry and light node APIs (forward-looking — not yet rendered natively)
Add the dependency to your pubspec.yaml:
dependencies:
sceneview_flutter: ^3.6.2Then run:
flutter pub getMinimum SDK 24. In android/app/build.gradle:
android {
defaultConfig {
minSdkVersion 24
}
}Minimum iOS 17. In ios/Podfile:
platform :ios, '17.0'The host app must also add SceneViewSwift via Swift Package Manager in Xcode:
- URL:
https://github.com/sceneview/SceneViewSwift - Version:
3.6.2
import 'package:sceneview_flutter/sceneview_flutter.dart';
final controller = SceneViewController();
SceneView(
controller: controller,
onViewCreated: () {
controller.setEnvironment('environments/studio_small.hdr');
controller.loadModel(const ModelNode(modelPath: 'models/damaged_helmet.glb'));
},
)import 'package:sceneview_flutter/sceneview_flutter.dart';
final controller = SceneViewController();
ARSceneView(
controller: controller,
planeDetection: true,
onViewCreated: () {
controller.loadModel(const ModelNode(modelPath: 'models/andy.glb'));
},
)| Method | Description |
|---|---|
loadModel(ModelNode) |
Load a glTF/GLB model into the scene |
clearScene() |
Remove all models from the scene |
setEnvironment(String path) |
Set HDR environment for image-based lighting |
addGeometry(GeometryNode) |
Add a geometry node (placeholder — not yet rendered) |
addLight(LightNode) |
Add a light node (placeholder — scene uses defaults) |
isAttached |
Whether the controller is attached to a live view |
| Property | Type | Default | Description |
|---|---|---|---|
modelPath |
String |
— | Asset path or URL to GLB/GLTF file |
x |
double |
0.0 |
X position in world space |
y |
double |
0.0 |
Y position in world space |
z |
double |
0.0 |
Z position in world space |
scale |
double |
1.0 |
Uniform scale factor |
Flutter (Dart)
|
+-- PlatformView -----> Android: ComposeView + SceneView { }
| (Filament renderer, SceneView SDK 3.6.2)
|
+-- PlatformView -----> iOS: UIHostingController + SceneViewSwift
(RealityKit renderer, SceneViewSwift 3.6.2)
Method channels bridge Dart commands (loadModel, clearScene, setEnvironment) to native implementations.
- Geometry and light nodes are not yet rendered natively (API exists for forward compatibility)
- AR tap-to-place is not yet implemented
- No event callbacks from native to Dart yet (
onTap,onModelLoaded) - Only Android and iOS are supported; other platforms show a fallback message
See CONTRIBUTING.md.
Apache-2.0 — see LICENSE for details.