Using the WMTSLayer introduced at v2.4 to access tiles from Iowa Mesonet, tiles are appearing in the incorrect order. The testing configuration is shown below. I have reversed the sign for the y-origin of the tileset in the test page. The tileset info from the provider has the y-origin as y="-20037508.340000". When the negative value is used for the y-origin in the map configuration, tiles are returned only for Level 0.Zooming in on the test page shows tiles offset down and to the left.A test page is available at: http://geologic.dyndns.org/new_nexrad2.htmlfunction init() {
var map = new esri.Map("map");
var startExtent = new esri.geometry.Extent({"xmin":-20037508.340000,"ymin": -20037508.340000, "xmax":20037508.340000,"ymax": 20037508.340000,"spatialReference": new esri.SpatialReference({"wkid":900913})});
map.setExtent(startExtent);
var tileInfo = new esri.layers.TileInfo({
"height" : 256,
"width" : 256,
"dpi" : "90.71428571427429",
"format" : "image/png",
"compressionQuality" : 0,
"origin" : {
"x" : -20037508.340000,
"y" : 20037508.340000
},
"spatialReference" : new esri.SpatialReference ({
"wkid" : 900913
}),
"lods" : [
{"level": "0", "resolution" : 156543.033928, "scale" : 559082263.9508},
{"level": "1", "resolution" : 78271.51695000000472646207, "scale" : 279541131.9754},
{"level": "2", "resolution" : 39135.75847500000236323103, "scale" : 139770565.9877},
{"level": "3", "resolution" : 19567.87923750000118161552, "scale" : 69885282.9939},
{"level": "4", "resolution" : 9783.93961875000059080776, "scale" : 34942641.4969},
{"level": "5", "resolution" : 4891.96980937500029540388, "scale" : 17471320.7485},
{"level": "6", "resolution" : 2445.98490468750014770194, "scale" : 8735660.3742},
{"level": "7", "resolution" : 1222.99245234375007385097, "scale" : 4367830.1871},
{"level": "8", "resolution" : 611.49622617187503692548, "scale" : 2183915.0936},
{"level": "9", "resolution" : 305.74811308593751846274, "scale" : 1091957.5468},
{"level": "10", "resolution" : 152.87405654296875923137, "scale" : 545978.7734},
{"level": "11", "resolution" : 76.43702827148437961569, "scale" : 272989.3867},
{"level": "12", "resolution" : 38.21851413574218980784, "scale" : 136494.6933},
{"level": "13", "resolution" : 19.10925706787109490392, "scale" : 68247.3467},
{"level": "14", "resolution" : 9.55462853393554745196, "scale" : 34123.6733},
{"level": "15", "resolution" : 4.77731426696777372598, "scale" : 17061.8367},
{"level": "16", "resolution" : 2.38865713348388686299, "scale" : 8530.9183},
{"level": "17", "resolution" : 1.19432856674194343150, "scale" : 4265.4592},
{"level": "18", "resolution" : 0.59716428337097171575, "scale" : 2132.7296},
{"level": "19", "resolution" : 0.29858214168548585787, "scale" : 1066.3648}
]
});
var tileExtent = new esri.geometry.Extent(-20037508.340000,-20037508.340000,20037508.340000,20037508.340000,
new esri.SpatialReference({wkid: 900913}));
var layerInfo = new esri.layers.WMTSLayerInfo({
tileInfo: tileInfo,
fullExtent: tileExtent,
initialExtent: tileExtent,
identifier: "nexrad-n0q-900913",
tileMatrixSet: "",
format: "png",
style: ""
});
var resourceInfo = {
version: "1.0.0",
layerInfos: [layerInfo],
copyright: "Mesonet"
};
var options = {
resourceInfo: resourceInfo,
layerInfo: layerInfo,
visible:true
};
var wmtsLayer = new esri.layers.WMTSLayer("http://mesonet.agron.iastate.edu/cache/tile.py/1.0.0/", options);
map.addLayer(wmtsLayer);
}
dojo.addOnLoad(init);
Tileset information is available from Iowa Mesonet at: (http://mesonet.agron.iastate.edu/cache/tile.py/1.0.0/nexrad-n0q-900913/)Additional information about the Iowa Mesonet service is available at: http://mesonet.agron.iastate.edu/ogc/