globe base color

Hi,

I wonder if it is easy to set the 'base' color for the globe in Cesium.

I have a tile set that uses transpartent PNGs that assumes a white
background color, but the default is dark blue.

Is there a simple way to change this?

best regards,

Akos

Hi,

If you’re building Cesium yourself, you can change the color on line 106 of Source/Shaders/CentralBodyFS.glsl. If you’re using our pre-built distribution, there’s no built-in way to do it. It wouldn’t be hard to add, and I’d welcome a pull request that does it. As a workaround, you could add a layer underneath your actual layer that is a SingleTileImageryProvider with global extent, where the single tile is just a single pixel of your desired color.

Kevin

Kevin,

If you're building Cesium yourself, you can change the color on line
106 of Source/Shaders/CentralBodyFS.glsl. If you're using our
pre-built distribution, there's no built-in way to do it. It wouldn't
be hard to add, and I'd welcome a pull request that does it. As a
workaround, you could add a layer underneath your actual layer that is
a SingleTileImageryProvider with global extent, where the single tile
is just a single pixel of your desired color.

thanks, at the end I went with the single color SingleTile image provider.

Akos

I opened an issue on GitHub for this issue so we don’t forget about it:

https://github.com/AnalyticalGraphicsInc/cesium/issues/726