Cesium.Viewer baseLayer

We are running CesiumJS version 1.104 and have addressed all of the deprecated items except the change from options.imageryProvider to options.baseLayer for the Cesium.Viewer.

If we use options.imageryProvider we get the deprecated warning message. But if we use options.baseLayer we get a rendering error.

Am I doing something wrong? Here’s a simple Sandcastle Example

If you comment out baseLayer and uncomment imageryProvider it works as expected.

Figured it out. Needed to use Cesium.ImageryLayer.fromProviderAsync to load the layer.

Sandcastle Example

1 Like