Dear all!
I have the following simple member in my JavaScript class describing tiled layers I want to load:
this._params['satellites'] = [{
'url': "/tiles/landsat-i-cubed"
}, {
'url': "/tiles/bmng-07-2004",
'maximumLevel': 2
}];
Layers' loading is implemented in the following way:
this._cesium = new Cesium.CesiumWidget(this._params['id']);
var layers = this._cesium.centralBody.getImageryLayers();
for (var i = 0; i < this._params['satellites'].length; i++) {
var satelliteImageryParams = this._params['satellites'][i];
if (satelliteImageryParams['url'].indexOf("/") === 0)
satelliteImageryParams['url'] = window.location.protocol + "//" + window.location.host + satelliteImageryParams['url'];
satelliteImageryParams = jQuery.extend(satelliteImageryParams, {
'tilingScheme': new Cesium.GeographicTilingScheme({
numberOfLevelZeroTilesX: 2,
numberOfLevelZeroTilesY: 1
})
});
var satelliteImageryProvider = new Cesium.TileMapServiceImageryProvider(satelliteImageryParams);
var satelliteLayer = new Cesium.ImageryLayer(satelliteImageryProvider);
layers.add(satelliteLayer);
}
As one can see both tile caches are organized according to caches provided by MapTiler. The only difference is that Landsat has some more detailed levels. What I want to achive is to display BMNG on high levels and then, say, starting from zoom level 3 overlay transparent Landsat. Setting maximumLevel to 2 in BMNG configuration array restricts tiles' requesting by level in the range [0; 2] but it doesn't affect layer's visibility - Cesium stretches the latest level 2 when I zoom in. As the result, Landsat is never shown.
I also tried to swap these two layers in the array and set minimumLevel of Landsat to 3. But it predictably led me to situation I've described in my
recent post.
Finally I've looked at documentation of
ImageryLayer and found nothing that could help to solve the problem. I'd expected to see some zoom level or metric parameters allowing to specify minimum and maximum positions of the camera a layer is visible from. Is it possible to achieve desired behavior using Cesium some way?
Thank you so much for attention!