Open kotran88 opened 1 year ago
i have same issue. i have tried to load .gltf file from assets. it working in ios but android app gives error "Unable to load renderable".
Some of my .GLTF
files are loading properly from assets but some of are giving the error like "Unable to load renderable"
I have the same issue, someone solved it?
I have the same issue, doesn't matter wether I use NodeType.localGLTF2
or NodeType.fileSystemAppFolderGLTF2
.
I have the same issue, some glb files are working but some are not working at all event no error message
I have the same issue.
I just used sample example on my project
only change I made is path from
"https://github.com/KhronosGroup/glTF-Sample-Models/raw/master/2.0/Duck/glTF-Binary/Duck.glb",
to
assets/f_5.glb
I checked gltf validator and has no problem. also I used this glb file on modelviewer.
wha tmakes error and not render on ar screen?
Future<void> onPlaneOrPointTapped( List<ARHitTestResult> hitTestResults) async { var singleHitTestResult = hitTestResults.firstWhere( (hitTestResult) => hitTestResult.type == ARHitTestResultType.plane); if (singleHitTestResult != null) { var newAnchor = ARPlaneAnchor(transformation: singleHitTestResult.worldTransform); bool? didAddAnchor = await this.arAnchorManager!.addAnchor(newAnchor); if (didAddAnchor!) { this.anchors.add(newAnchor); // Add note to anchor var newNode = ARNode( type: NodeType.webGLB, uri: "assets/f_5.glb", scale: Vector3(0.2, 0.2, 0.2), position: Vector3(0.0, 0.0, 0.0), rotation: Vector4(1.0, 0.0, 0.0, 0.0)); bool? didAddNodeToAnchor = await this .arObjectManager! .addNode(newNode, planeAnchor: newAnchor); if (didAddNodeToAnchor!) { this.nodes.add(newNode); } else { this.arSessionManager!.onError("Adding Node to Anchor failed"); } } else { this.arSessionManager!.onError("Adding Anchor failed"); } /* // To add a node to the tapped position without creating an anchor, use the following code (Please mind: the function onRemoveEverything has to be adapted accordingly!): var newNode = ARNode( type: NodeType.localGLTF2, uri: "Models/Chicken_01/Chicken_01.gltf", scale: Vector3(0.2, 0.2, 0.2), transformation: singleHitTestResult.worldTransform); bool didAddWebNode = await this.arObjectManager.addNode(newNode); if (didAddWebNode) { this.nodes.add(newNode); }*/ } }
ar_flutter_plugin: ^0.7.3 vector_math: ^2.1.4
flutter doctor :