Mapbox Issue When Publishing

Hi, I like the new mapbox maps for my project and got them working in sandcastle but when I publish them my app hangs on the “Loading…” screen. So i took the “Hello World.html” that comes with Cesium (the one in …/gallery) and replaced the “var viewer…” line with the following code:

var viewer = new Cesium.Viewer(‘cesiumContainer’, {
baseLayerPicker : false,

imageryProvider : new Cesium.MapboxImageryProvider({

mapId: ‘mapbox.satellite’,

accessToken : ‘pk.eyJ1IjoiYm1haXJzcGFjZSIsImEiOiJhZjM0NzlmM2JjMzQwMDVjYmNjNmEyZjkxMTc2NzQ1ZSJ9.NcIIXL1PQhpKIZAwxpH6cg’

})

});

``

and I published it at the following link, try it for yourself:

http://www.88nv3d.com/Cesium/Apps/Sandcastle/gallery/Hello%20World%20Mapbox.html

Given it works in sandcastle, I’m not sure what i’m doing wrong. Any help is appreciated. Thanks!!

-Justin

And yes i’m running 1.12.

http://www.88nv3d.com/Cesium/CHANGES.md

And yes the regular “Hello World.html” works

http://www.88nv3d.com/Cesium/Apps/Sandcastle/gallery/Hello%20World.html

Hello Justin,

I went to your mapbox sandcastle link (http://www.88nv3d.com/Cesium/Apps/Sandcastle/gallery/Hello%20World%20Mapbox.html) and everything worked fine. Can you give me any more information about the problem you are having? Are there any errors written to the console?

Thanks,

Hannah

For me the mapbox example never gets past the “Loading…” screen. I think release 1.12 might have broke something in Chrome as my larger app is having the same problem with 1.12 but not 1.11 (example below). I’m using Version 44.0.2403.130 m). I tried enabling the “Override software rendering list” but that didn’t help. Are you using Chrome?

Cesium 1.12 gets stuck on “Loading…”

http://www.88nv3d.com/Cesium/Apps/Sandcastle/gallery/BM3.html

Note: If i use a Mac running Chrome in Parallels this works…but the “Hello World Mapbox.html” still hangs on loading

Cesium 1.11 works fine

http://www.88nv3d.com/Cesium1.11/Apps/Sandcastle/gallery/BM3.html

In Firefox (v 39)

Both links above load fine and so does the “Hello World Mapbox.html” link in my original post. But i can’t use firefox because all my polygons and polylines just randomly disappear all the time (but that’s always been a problem in ff).

Hmm… both your 1.12 and 1.11 versions load fine for me in chrome. I just updated to Version 44.0.2403.130 m and now your application loads even more quickly than it did before I updated. I’m on a windows machine, but I don’t think that would make a difference.
Are the drivers for your video card up to date? Are you able to run the unit tests for 1.12?

Interesting. It always seems to load faster the second time you load it in a new browser for me too. I ran the unit tests. 16 failures…14 having to do with these two. By enabling the “Override software rendering list” flag in chrome://flags/, it should ignore any video cards flagged as being insecure and therefore turned off for webGL.

This is out of my league when it comes to Cesium though…

Did you clear out your cache? Sometimes I see weird issues in chrome because it cached something. I almost always run chrome in incognito mode when doing development because of that.
I wouldn’t expect to see test failures in either CameraEventAggregator or ScreenSpaceCameraController. There haven’t been significant changes to either of those classes in a long time.

Everything worked great in incognito mode.

Cleared the cache, now everything works great in regular mode.

So simple, yet so helpful. Thanks!!!

-Justin

PS: the unit test results didn’t change post cache clearing. But it doesn’t seem to be having an impact.