marlonjd / babylonjs_viewer Goto Github PK
View Code? Open in Web Editor NEWFlutter 3D Model Viewer with BabylonJS Viewer
License: MIT License
Flutter 3D Model Viewer with BabylonJS Viewer
License: MIT License
Is there a method to display the loading progress in percentage for the src
file in https
?
่ฝๅฆไธๆพๅคงไธ็ผฉๅฐๅ่ฝ๏ผ
Thanks for your great effort :)
I'm just wondering if there are any more functions beside basic 3D viewer.
ex) Turning on AR when button pressed, changing model viewer's background
Thank you :)
I run and get below issue, please guide:
E/FrameEvents( 3079): updateAcquireFence: Did not find frame.
ๅฆๆ ้ขๆ็คบ
I think its because the underlaying webview doesnt have a controller.
Could we mabye get reloadmodel function into this plugin? , and use a controller within the webview, I think that should do it.
I have testcode here, just add 2 .glb files to assets.:
import 'package:flutter/material.dart';
import 'package:babylonjs_viewer/babylonjs_viewer.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@OverRide
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter DropDownButton',
theme: ThemeData(
primarySwatch: Colors.green,
),
home: const MyHomePage(),
debugShowCheckedModeBanner: false,
);
}
}
class MyHomePage extends StatefulWidget {
const MyHomePage({Key? key}) : super(key: key);
@OverRide
_MyHomePageState createState() => _MyHomePageState();
}
class _MyHomePageState extends State {
String dropdownvalue = 'assets/test1.glb';
late BabylonJSViewer bsv;
@OverRide
void initState() {
super.initState();
bsv = BabylonJSViewer(
src: dropdownvalue,
);
}
var items2 = [
'assets/test1.glb',
'assets/alpha-blend-litmus.glb',
];
@OverRide
Widget build(BuildContext context) {
bsv = BabylonJSViewer(
src: dropdownvalue,
);
return Scaffold(
appBar: AppBar(
title: const Text("3d models"),
),
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
DropdownButton(
value: dropdownvalue,
icon: const Icon(Icons.keyboard_arrow_down),
items: items2.map((String items2) {
return DropdownMenuItem(
value: items2,
child: Text(items2),
);
}).toList(),
onChanged: (String? newValue) {
setState(() {
dropdownvalue = newValue!;
bsv = BabylonJSViewer(
src: newValue,
);
print(dropdownvalue);
});
},
),
Expanded(child: bsv),
],
),
),
);
}
}
flutter sdk 2.10 ๏ผbabylonjs_viewer 1.1.1 android 7.0็ณป็ปๆๆบๆพ็คบ้ข่ฒไธๆญฃๅธธ๏ผhttps://modelviewer.dev/shared-assets/models/NeilArmstrong.glb
hi, is it possible to remove the grey background caused by i believe the ambient light?
When i try to load a .glb model from a web link there is this error:
Unable to import meshes from /modelLink.glb: Error status: 0
it only works with this models:
https://modelviewer.dev/shared-assets/models/NeilArmstrong.glb
https://models.babylonjs.com/boombox.glb
I received the folllowing error,while loading the example.
`โโโโโโโโ Exception caught by widgets library โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
The following _CastError was thrown building BabylonJSViewer(dirty, state: _BabylonJSViewerState#21ec1):
Null check operator used on a null value
The relevant error-causing widget was
BabylonJSViewer
lib/ui/sample.dart:23
When the exception was thrown, this was the stack
#0 _BabylonJSViewerState.build
package:babylonjs_viewer/src/babylonjs_viewer.dart:61
#1 StatefulElement.build
package:flutter/โฆ/widgets/framework.dart:4691
#2 ComponentElement.performRebuild
package:flutter/โฆ/widgets/framework.dart:4574
#3 StatefulElement.performRebuild
package:flutter/โฆ/widgets/framework.dart:4746
#4 Element.rebuild
package:flutter/โฆ/widgets/framework.dart:4267
...
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ`
ๆ ๆณไฟฎๆนๅบๆฏ้ป่ฎค้ข่ฒ
Can i display .fbx object?
How?
Hi,
newbie here! I am trying to build a simple example, but it says:
[ +8 ms] FAILURE: Build failed with an exception.
[ +3 ms] * What went wrong:
[ ] The Android Gradle plugin supports only Kotlin Gradle plugin version 1.5.20 and higher.
[ ] The following dependencies do not satisfy the required version:
[ ] project ':flutter_gl' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.61
but the flutter_gl plugin should be alreay updated... did i miss some setting?
Thanks!!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.