Is it possible to encode a multi-band raster using LERC tiles generated by ArcGIS Server 10.3?

I currently use the Composite Bands raster function to combine three rasters (16 bit unsigned integer, 4 bit integer, and 32 bit float). These are combined in a mosaic dataset.

I can successfully share this (Share as Image Service) without caching the data. When I connect to the server in ArcMap and Identify the image service, I get all three raster values for the location of interest. I then modify the service properties however, selecting Caching >> Using tiles from Cache, Update cache manually and Caching >> Advanced Settings >> tile format: LERC, Create tiles on demand.

I can view the tiles in the example viewer (source here, my implementation here). However, when I log the results to the console, I'm only seeing values from the first raster (ranging from 15000 to 17000).

Looking at the LERC documentation, they do suggest that multiple bands are possible:

One more comment about multiple bands. You can either store each band into its own Lerc byte blob which allows you to access / decode each band individually. Lerc also allows to stack bands together into one single Lerc byte blob. This can be useful if the bands are always used together anyway.

Is it possible to implement this using ArcGIS server out of the box? Or do I need to create tiles for three image services, then combine them in the browser?

1 Answer 1


The folks at esri have written additional code to enable reading multi-band LERC rasters. From the issue on github:

The current js decoder does the bare minimum. To decode a multi-band pixel block, client needs to keep decoding until it reaches the end of the stream. We're planning to make this out of the box when lerc2 v3 JS decoder is available.

I just uploaded a wrapper function to the js-lerc2 branch. The updated sample index.htm in js-lerc2 branch now supports any band (it draws the first three for multispectral data). Here is a sample request you can use.

The updated code is currently available in the js-lerc2 branch but will likely be merged when lerc2 v3 JS decoder is available.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.