AB95 Posted February 14, 2017 Share Posted February 14, 2017 Hi everyone, I am working on a scene that requires import meshes from .babylon file, most of the time I debug the scene on android mobile browser, and I got this error while trying to load the scene in iphone 5 & 6 (ios 10.2.1 up to date)safari browser: Error status: 0 - Unable to load myfile.babylon this is the link of the webpage http://52.74.240.184/infographics/game_RisingSeaLevel/. I have no problem loading the scene on desktop, android mobile browser(chrome, firefox, opera), however, when I try to load the scene on iphone 6, most of the times I encounter the above error during the middle of importing mesh, if you open the webpage using iphone, there is a chance for you to stuck in the loading screen, when the error occurs. Nonetheless, there is a few times the scene can be successfully loaded, but only a few times. May I know if anyone who ever got with this error knows what is going on, as I am mainly working on the content of the 3D scene rather than handle the back-end part, thanks! Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 14, 2017 Share Posted February 14, 2017 Hello, iOS is a pile of crap when dealing with WebGL, it is the new IE6 if the file is big, you can try to cut it into smaller parts using the incremental loading system: http://doc.babylonjs.com/tutorials/using_the_incremental_loading_system Other thing to check: Did you turn on the gzip compression of .babylon file on your server? Quote Link to comment Share on other sites More sharing options...
AB95 Posted February 15, 2017 Author Share Posted February 15, 2017 hi @Deltakosh, the gzip compression is on, and after I convert .babylon file into .incremental.babylon file, same link: http://52.74.240.184/infographics/game_RisingSeaLevel/ the first few time i am finally able to enter the scene using iphone 6 safari, but as I tested again for a few more times(every time I clear safari cache before open the webpage again), more errors shows out, an error similar as previous one shows up again: Error status: 0 - Unable to load fileRoot/myScene.someOfMySceneMeshName.babylonmeshdata I am surprise as there are some of the .babylonmeshdata that have this error which are actually quick small in size. also there is a new error: Cross-origin image load denied by Cross-Origin Resource Sharing policy. I am not familiar with server side knowledge, but since the scene is not hosted locally, I wonder why cross-origin error still occurs... Also this times of using incremental babylon file, these error occurs on almost all iphone (5, 6, 6s as i asked friend to help me test), previously when I use non incremental babylon file to import mesh into the scene, iphone 6s seems to have no issue, although it could be iOS having a good day and decide to have a success loading on some of the iphone brand. iOS is really giving me a huge pain... Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 15, 2017 Share Posted February 15, 2017 At least we know it is not related to the size of assets Are you seeing any issue with this scene: http://www.babylonjs.com/Demos/Sponza/ ? If not at all then there is something in your scene configuration that iOS dislikes I would suggest trying to export without textures, or without big objects, etc.. to try to reduce the list of potential suspects Regarding the cross-origin issue, this happens when you load an image or a texture from a different url that the one the page is hosted on. Quote Link to comment Share on other sites More sharing options...
AB95 Posted February 16, 2017 Author Share Posted February 16, 2017 @Deltakosh the Sponza scene loads perfectly on the iphone 6 that previously having issue loading my page. And in fact, I just enable offline support by setting up the manifest file. And unexpectedly, after I did that, error's gone, I am able to enter the scene again, but I am uncertain about how reliable this is as it took me a few times of clear cache and reload to finally enter the scene. Also, regarding the offline support, may i ask, will clear cache also remove offline resource? Once I clear cache, do I have to change the version number in manifest file in order to download assets again? Thanks. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 16, 2017 Share Posted February 16, 2017 clearing the cache (and the IDB base) should do the trick Glad that you find a way to make it work 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.