Imagery from ArcGIS ImageServers

var imageProvider = new Cesium.UrlTemplateImageryProvider({

url: ‘{westProjected}%2C{southProjected}%2C{eastProjected}%2C{northProjected}&bboxSR=&size=&imageSR=&time=&format=jpgpng&pixelType=U8&noData=&noDataInterpretation=esriNoDataMatchAny&interpolation=+RSP_BilinearInterpolation&compression=&compressionQuality=&bandIds=&mosaicRule=&renderingRule=&f=image


var imageLayer = new Cesium.ImageryLayer(imageProvider);


I appreciate any help!




I have seen that “UrlTemplateImageryProvider” is to be used in order to pull in imagery from ArcGIS ImageServers, but I am having difficulty understanding how to implement it.
There was a previous post here, where someone loosely described how to import it, but: I couldn’t understand their explanation, nor could I get their code to work in Sandcastle.

This was his code:

var c = new Cesium.Viewer(‘cesiumContainer’);

Hi Peter,

UrlTemplateImageryProvider allows you to use any imagery server, so long as you tell the API where required meta-information should be included in the url string. As a simplified example, if had a tile server that gave me tile 0/0/0 with the url, the url template would be{x}/{y}/{z}.

In actuality, a feel more parameters are required, which you can read about here:

The example from the thread you linked to worked for me. See it again here:

Side note: in the future, you can share code more easily by creating a code example in Sandcastle then clicking the “Share” button up top to save your code as a gist then generate a link to the saved code in Sandcastle. You can read more about Sandcastle tips (there are a lot of really useful ones!) here:

Hope that helps,

  • Rachel