Rotate globe (not camera)


I need to animate a day/night cycle from a fixed camera position i.e. the globe rotates but the perceived position of the lightsource remains constant. I've had a dig around the documentation for Ellipsoid and Globe but I can't see an obvious way to do this - is it possible, or is there another approach I can use?

Thanks for any help,



See Transforms.computeIcrfToFixedMatrix and Globe.enableLighting.

It’s not on github yet, but I cleaned up the example code for computeIcrfToFixedMatrix to be just:

var clock = viewer.clock;

clock.onTick.addEventListener(function() {

var icrfToFixed = Cesium.Transforms.computeIcrfToFixedMatrix(clock.currentTime);

if (Cesium.defined(icrfToFixed)) { = Cesium.Matrix4.fromRotationTranslation(icrfToFixed, Cesium.Cartesian3.ZERO);