neonwarge04 Posted October 18, 2015 Share Posted October 18, 2015 I would like to try pixi directly from browser since I was task to do something like this for some reasons and I cannot question. How can I run PIXI.js on mobile browsers? I am not going to use CocoonJS or any of this javascript appify third-parties, I just want to run pixi on mobile browser.So here's what I did, I pasted the entire project folder into my device and load the index.html from there, I can't get it to work of course due to some CORS/Http request which I think is a major hindrance in what I am trying to do. Do I have to to something fancy, like deploying a lite-server into my device to try this on? If not, how am I suppose to do this? THe project I am working on is browser-base game, so the only way to access the game is through the browser. I am tasked to check performance of pixi (Of course, as advertised, is fast, which I believe) but you know the top management won't take advertisement as proof and would rather see an actual game performing. I really don't know how to get around this on mobile browser. I'll appreciate your help!Thank you! Quote Link to comment Share on other sites More sharing options...
icp Posted October 18, 2015 Share Posted October 18, 2015 Your issue is that : Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https, chrome-extension-resource.You will need to deploy your content to a server and enter the URL in your smartphone browser. You can use Google Drive, Dropbox or a FTP server ( ex: myapp.com/index.html). neonwarge04 1 Quote Link to comment Share on other sites More sharing options...
neonwarge04 Posted October 18, 2015 Author Share Posted October 18, 2015 Oh I see, so thats how you do it! Great thanks!!! Quote Link to comment Share on other sites More sharing options...
neonwarge04 Posted October 18, 2015 Author Share Posted October 18, 2015 I found this article:https://support.google.com/drive/answer/2881970?hl=enIt says it will be depcreated next year of August. Also, I am having the CORS file request related errors. Quote Link to comment Share on other sites More sharing options...
icp Posted October 18, 2015 Share Posted October 18, 2015 I personally use webhosting and everything works fine. Quote Link to comment Share on other sites More sharing options...
mattstyles Posted October 22, 2015 Share Posted October 22, 2015 You can usually fire up a server fairly simply on your own machine for local dev, which, depending on your machine setup would also make sharing over the local network trivial. If you have node and npm on your machine, which makes using modules in JS easy peasy, even in the browser, then the serve module will take the pain away, although there are countless others. Python also runs a super simple http server if python is installed on your machine, theres a guide here. There are other ways too, your machine might have apache installed which also makes this whole shindig rather easy. 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.