0
votes

I've recreate Basic Scene in simple .html document and it dont work properly in Chrome, only in Firefox Nightly. Need some help, thnks.

Chrome: doesn't load textures enter image description here


Nightly: everythig is ok enter image description here

1
Please add your code, otherwise there is not much we can do to help you. - marche
Sry, my bad <html> <head> <script src="https://aframe.io/releases/0.4.0/aframe.min.js"></script> </head> <body> <a-scene> <a-assets> <img id="boxTexture" src="https://i.imgur.com/mYmmbrp.jpg"> </a-assets> <a-box src="#boxTexture" position="0 2 -5" rotation="0 45 45" scale="2 2 2"></a-box> <a-sky color="#522"></a-sky> <a-light type="ambient" color="#445451"></a-light> <a-light type="point" intensity="2" position="2 4 4"></a-light> </a-scene> <body> </html> - Andy Griffits
Hmm. A-Frame should be injecting crossorigin flag on those images. It works for me on Chrome. Console issues? - ngokevin
@ngokevin there's screenshot of errors link - Andy Griffits

1 Answers

0
votes

I guess you are experiencing a browser inconsistency when accessing files from your computer directly (i.e. the address starts with file:// instead of http:// or https://).

If you open this JSFiddle, you will see the texture both in Chrome and Firefox.

Chrome is stricter than Firefox when it comes to loading data from your local filesystem. To work around this, you can run a local webserver or use JSFiddle, JSBin, Codepen or Glitch.