The below post is replicated from ESRI’s ArcGIS Ressource Center’s Blog. This post was written by Rajinder Nagi, Cartographic Researcher and is located at: Link. It is a wonderful capability that I have tried to figure out many times. This blog post will help me the next time I want to make terrain on my web maps look more realistic. Here is the blog post:
A very common cartographic technique used by many map makers is to transparently overlay a colored raster, called a layer tint, over a grayscale raster, like a hillshade or a panchromatic aerial or satellite image (figures 1 and 2).
Figure 1. A grayscale hillshade
Figure 2. A layer tint of elevation
This results in a display that has a washed out version of the layer tint and a less detailed version of the grayscale raster (figure 2).
Figure 3. The result when the layer tint is shown with 40% transparency over the hillshade
In a previous blog post, we described how you can use a special set of functions with mosaic datasets and a color map file to better display colored rasters over grayscale rasters. The result retains both the original colors and the grayscale detail in the input rasters (figure 4).
Figure 4. The result when image functions are used to control the display
In this article, we describe how you can obtain the same results using a color ramp rather than a color map file and Image Analyst rather than a mosaic dataset. The objective is to demonstrate the versatility of this display method, regardless of how you are working with your rasters.
At the core of this display method is a combination of pan sharpening, contrast stretching, and gamma stretching functions. The pan sharpening function uses a panchromatic and a multispectral (3-band RGB) raster as input. In the example here, a hillshade created from a DEM is the panchromatic raster and a DEM with a color ramp that has been converted to a multispectral raster are the inputs. The output from the pan sharpening function is then used as input for the contrast and gamma stretching functions.
Since layer tinted DEMs are not usually managed as 3-band RGB rasters, a conversion is required. To do this, add the DEM to ArcMap, right-click the layer in the table of contents, and click Properties. On the Symbology tab, select the color ramp you want to use to display the data. Click OK to close the Layer Properties dialog box. Right-click the layer in the table of contents, click Data, and click Export Data. In the Export Raster Data dialog box, check Use Renderer and check Force RGB. Choose a location and input a name, then click Save. Choose to add the exported data to the map as a layer. The 3-band RGB image will be added to the table of contents.
At this point, you can either follow the steps described in the previous article to add the raster to a mosaic dataset and render it, or you can use the instructions below if you want to use the Image Analysis tools rather than a mosaic dataset.
Define the Functions for the raster datasets
- Add the grayscale hillshade and multispectral RGB layer tint rasters to ArcMap, if they have not already been added.
- Open the Image Analysis window by clicking Windows on the top bar menu, then clicking Image Analysis.
- In the top section of the Image Analysis window, select both the hillshade and RGB rasters using the Control key and clicking on each raster’s name to highlight it (figure 5).Figure 5. The Image Analysis window
- Click the Pan-Sharpening tool in the Processing section of the Image Analysis Window. This will create a new layer which will be listed as the top layer in the Image Analysis Window.
- In the Image Analysis Window, right-click the newly generated pan-sharpening layer and click Properties.
- On the Functions tab, right-click the Pansharpening Function and click Properties.
- On the General tab of the Raster Function Properties dialog box change the Output Pixel Type to 8 Bit Unsigned.
- On the Pan Sharpen tab, change the Method to Simple Mean.
- Keep the rest of the defaults and click OK.
- Right click Pansharpening Function, click Insert, and click Stretch Function.
- Change the Type to Minimum-Maximum.
- Check the Use Gamma option.
- In the Gamma section of the dialog box, change the Gamma value from 1.0 to 0.5 for each of the three bands.
- In the Statistics section of the dialog box, type 5 as the Min and 215 as Max values for each of the three bands. The final function chain will look like figure 6.
Figure 6. The final function chain
- Click OK to check your results.
After checking the results, feel free to experiment with the Gamma, minimum, and maximum values in the Stretch Function.
NOTE: Creating your display using the Image Analysis Window instead of mosaic datasets results in a temporary raster. If you want to keep your results, remember to export the layer that you added the functions to from ArcMap.
If you want to try this out yourself, download this .zip file which contains a map package of the Washington elevation map used in this article.
Thanks to Aileen Buckley, Mapping Center Lead, for her help with this blog entry!
Filed under: ESRI, Mapping | Leave a comment »