Pryme8 Posted May 3, 2017 Share Posted May 3, 2017 Back from the dead ^_^_^ MUAHAHAHA.... Anyways, I am loading an external STL, and everything seems to be going as planned. The file loads but nothing ever appears in the draw stack. It shows that there is a loaded mesh, that it contains polygonal data etc, but the draw calls remain at 0. Its been a while seine I have worked in BJS so I kinda don't even know where to start debugging this. This is the STL file https://s3-us-west-1.amazonaws.com/kirakira-dev/user-photos-main/577bfb3b6aa5717c0c06af6c/user-photos/1483735045390group_lmnop.stl and here is a screenshot of the debug layer: Any help on this would be greatly appreciated. Quote Link to comment Share on other sites More sharing options...
Pryme8 Posted May 3, 2017 Author Share Posted May 3, 2017 Ok I think I may be doing it wrong... Do I have to load the STL with BABYLON.SceneLoader.Load()? and not the asset manager? I found but the information on there was not much help. Does anyone have a working example of a STL being loaded (ASCII because of no binary support) The thing that is tripping me out is the fact there are no draw calls though there is and active mesh. Here are two playgrounds showing it does not work:https://www.babylonjs-playground.com/#VSVK9G#1 - this one is using the AssetManagerhttps://www.babylonjs-playground.com/#VSVK9G - this one is using the SceneLoader The SceneLoader one does not even finish up because of an error in the STL loader. I have also tried the a different STL file to verify and im getting the same errors it seems:https://cdn.coursesaver.com/files/Part26-4.STL at least on the SceneLoader it seems to work when I use the AssetManager. **Kinda Solved... Im thinking its just because some of the STL files are crap...https://www.babylonjs-playground.com/#VSVK9G#2 Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted May 3, 2017 Share Posted May 3, 2017 Welcome back Asset manager should just work..Do you mind sharing the code used? Quote Link to comment Share on other sites More sharing options...
Pryme8 Posted May 3, 2017 Author Share Posted May 3, 2017 Just added some playgrounds. I think the problem I was having is some of the STL's were binary and some of them were also badly formatted ASCII.https://www.babylonjs-playground.com/#VSVK9G#1 Kinda stumps me though, it looks like the mesh loaded but I get no draw calls... I pretty much moved onto a different STL and the issues stopped, but thought this was weird behavior. Is it because the mesh is not in the cameras view? Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted May 3, 2017 Share Posted May 3, 2017 I can see it if you move the camera. So it is correctly loaded but not just in the frustum. Perhaps you can call camera.setTarget(yourMesh) ? Quote Link to comment Share on other sites More sharing options...
Pryme8 Posted May 3, 2017 Author Share Posted May 3, 2017 Ok so it was just the binary files that were giving me trouble. thanks for your help! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.