Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

is it possible to display multiple 3d models? #29

Closed
kibu7 opened this issue Jun 12, 2022 · 3 comments · Fixed by #31
Closed

is it possible to display multiple 3d models? #29

kibu7 opened this issue Jun 12, 2022 · 3 comments · Fixed by #31
Labels
bug Something isn't working question Further information is requested

Comments

@kibu7
Copy link

kibu7 commented Jun 12, 2022

is it possible to display multiple 3d models?
I have two ModelViewer but both are diplaying the same model

My code:
SizedBox( height: 300, width: 300, child: ModelViewer( src: 'https://modelviewer.dev/shared-assets/models/Astronaut.glb', alt: "A 3D model of an astronaut", ar: true, autoRotate: true, cameraControls: true, ), ), SizedBox( height: 500, width: 500, child: ModelViewer( src: 'https://modelviewer.dev/shared-assets/models/NeilArmstrong.glb', alt: "A 3D model of an astronaut", ar: true, autoRotate: true, cameraControls: true, ), ),
is there a way to displaying mutliple or can i just display one 3d model?
thank you for tips

@kibu7 kibu7 added the bug Something isn't working label Jun 12, 2022
@omchiii omchiii added the question Further information is requested label Jun 13, 2022
@jamesninnes
Copy link

I'm having the same issue, it also persists when navigating to different pages. Whatever is the first model I load into the app is the one that is displayed everywhere.

Foldblade added a commit to Foldblade/model_viewer_plus.dart that referenced this issue Jun 22, 2022
### Changed

- `README.md`: `import 'package:model_viewer_plus/model_viewer.dart';` -> `import 'package:model_viewer_plus/model_viewer_plus.dart';`
- `lib\html_builder.dart`: fix typos and uncomment `debugPrint` for more debug info
- `lib\model_viewer_plus_mobile.dart`: uncomment `debugPrint` for more debug info
- `lib\model_viewer_plus_web.dart`: unique viewType to fix [omchiii#29](omchiii#29)
- Update `assets/model-viewer.min.js` to v1.20.0
@Foldblade Foldblade mentioned this issue Jun 22, 2022
@Foldblade
Copy link
Collaborator

Hello @kibu7 @jamesninnes, guessing you both using model_viewer_plus on Web?

I think I've found the problem: #31

@kibu7
Copy link
Author

kibu7 commented Jun 22, 2022

hey @Foldblade, yes im using it on Web

omchiii added a commit that referenced this issue Jun 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants