Blend a hillshade with a raster by specifying the elevation data. The resulting raster looks similar to the original raster, but with some terrain shading, giving it a textured look.
Blend renderer can be used to apply a color ramp to a hillshade to emphasize areas of high or low elevation. A Blend renderer can also be used to add a hillshade effect to aerial or satellite imagery, thereby making changes in elevation more visible.
Tap the bottom button to choose and adjust the altitude, azimuth, slope type and color ramp type settings to update the image.
- Create an
AGSRaster
object from a raster file. - Create an
AGSRasterLayer
object from the raster. - Create an
AGSBasemap
object from the raster layer and set it to the map. - Create another
AGSRaster
object for elevation from a grayscale raster file. - Create an
AGSBlendRenderer
object, specifying the elevation raster, color ramp, and other properties.- If you specify a non-nil color ramp, use the elevation raster as the base raster in addition to the elevation raster parameter. That way, the color ramp is used instead of the satellite imagery.
- Set the blend renderer to the raster layer.
- AGSBlendRenderer
- AGSColorRamp
- AGSRaster
- AGSRasterLayer
This sample uses the Shasta.tif
and Shasta_Elevation.tif
resources. They are downloaded from ArcGIS Online automatically.
color ramp, elevation, hillshade, image, raster, raster layer, visualization