In my tile server, I’m having a couple of issues that have me a bit perplexed.
First, if I enable grid lines and labels identical to what is demonstrated on the Cesium sand castle site, any requests for tiles don’t match what I’m seeing in terms of the grid lines. The level is one greater, the x is typically correct, and the y is not even close. I create the imagery provider using the code below.
Additionally, when trying to debug my code, I request the east, west, north, and south degrees to be sent in Cesium’s http request. The received values seem to be in integer form only, so 86W, 34N for my neck of the woods. Wireshark shows that the data is being sent with the desired decimal portion, but I don’t know if the decimal (period) character is throwing my web server implementation for a loop. I’m using Sameke express for the server portion of my tile server, so it may be that the decimal portion is being stripped out or incorrectly parsed. I just don’t know.
let url = this._mapBaseUrlPreference.baseUrl +
'/wmts/default/256/{z}/{x}/{y}/{westDegrees}/' +
'{northDegrees}/{eastDegrees}/{southDegrees}';
// NOTE: defaults to web mercator tiling scheme
let urlProvider = new Cesium.UrlTemplateImageryProvider({
url: url,
minimumLevel: 1,
maximumLevel: 23
});
this._viewer.imageryLayers.addImageryProvider(urlProvider);