TileOutOfRange

Hi

I’m trying to use a WebMapTileServiceImageryProvider. The server is a GeowebCache.
The layer don’t cover the world but only the area I want to see.

Here is the definition of my WebMapTileServiceImageryProvider :
var basemapWMTSTexture = new Cesium.WebMapTileServiceImageryProvider({
url : geoServerURL +"/geowebcache/service/wmts",
layer : ‘map4326’,
style : ‘default’,
format : ‘image/jpeg’,
tileMatrixSetID : ‘EPSG:4326_map4326’,
tileMatrixLabels : [‘EPSG:4326_map4326:0’, ‘EPSG:4326_map4326:1’,
‘EPSG:4326_map4326:2’, ‘EPSG:4326_map4326:3’,
‘EPSG:4326_map4326:4’, ‘EPSG:4326_map4326:5’,
‘EPSG:4326_map4326:6’, ‘EPSG:4326_map4326:7’,
‘EPSG:4326_map4326:8’, ‘EPSG:4326_map4326:9’,
‘EPSG:4326_map4326:10’, ‘EPSG:4326_map4326:11’,
‘EPSG:4326_map4326:12’],
rectangle: new Cesium.Rectangle(
Cesium.Math.toRadians(20),
Cesium.Math.toRadians(20.),
Cesium.Math.toRadians(50),
Cesium.Math.toRadians(30)),
maximumLevel: 12

    });

Note that the WMTS getcapabilities explains that there is a MinTileRow, MinTileCol, MaxTileRow, MaxTileCol for each level.

Cesium throw this error
An error occurred in “WebMapTileServiceImageryProvider”: Failed to obtain image tile X: 1 Y: 0 Level: 1.

In fact the gewebcache return the following response :



Column 1 is out of range, min: 92 max:97

It would help to add MinTileCol, MaxTileRow, MaxTileCol for each level or add the getcapabilites response in order to define the WebMapTileServiceImageryProvider…

Any Idea to get around this ?

Hello, I took in consideration these parameters in my pull to Cesium https://github.com/AnalyticalGraphicsInc/cesium/pull/2362 . Now I'm waiting a validation and a merging of my contribution in master branch in order to help you.