Creating multiple image services from one multiband image service definition

When the client is ArcMap or the image service is published using WCS capabilities, the client has the capability to modify the band combination. However, for several other clients they can only accept a single or RGB band combination. When you need to serve multiple band combinations from a single data source, you can create image service definitions with limited band combinations referencing an image service definition containing all the bands.

One of the biggest reasons to build this kind of image service definition is to save time. If there are a lot of input raster datasets, it can take several hours to add the data to an image service definition and generate the service overviews. If you are going to output many image service definitions using the same input data, it can save you time to use the workflow outlined below.

For this workflow, Landsat 7 ETM imagery will be used. There are six bands (1–5 and 7) in this dataset that will be used to create many multiband combinations.

Creating the base image service definition

This base image service definition will contain all six bands.

步骤:
  1. Use the Advanced option to create a new image service definition.

    • Change Service Type to Custom.
    • Change Number of Bands to 6.
    • Change Color space to Unknown.

  2. Use the Advanced option to add raster datasets.

    • On the Image Service Definition Editor toolbar, click the Image Service drop-down arrow, point to Advanced, then click Add Raster Dataset to open the Select Raster Type dialog box.

      In this case, you will be using the Landsat-7 Level 1G raster type from the Georeferenced Imagery folder.

    • Use the Select Folder option to add the Landsat raster datasets.
    • On the Landsat 1G Parameters dialog box, set all the band sources to be in numerical order rather than the default. This makes it easier to remember how each input band was organized within the folder.
      Landsat Parameters dialog box
    • You should also apply an enhancement to the data being added; for example, set Percentile Stretch Method to 0.05% and Fixed value Gamma Method to 1.2.

  3. Build the image service definition.

    Accept the default checked options.

  4. Use the Advanced option to create service overviews.

    Change Compression Method to Uncompressed. This is because the TIFF files that will be created for the service overviews will have six bands, and it's not possible to compress a six-band TIFF file in this software. Alternatively, change the format to JPEG 2000.

  5. Use the Advanced option to build the service overviews.

    On the Build dialog box, check Generate derived images.

    You have now created the image service definition that you will use as the base to create all the other image service definitions of particular band combinations.

Save a linked copy of the base image service definition

步骤:
  1. Use the Advanced option Save As to save a copy.

    • Change the values for Service definition name and Service name.
    • Check Link to current Service Table.
    • Check Link to current Raster Datasets.
    • Check Link to current Service Boundary.

Add the Extract Bands service process

步骤:
  1. Open the Image Service Properties dialog box (from the Image Service Definition Editor toolbar 影像服务属性).
  2. Click the Service Process node.
  3. Add the Extract Bands process to the Processes Selected list.
  4. Open the Extract Bands process to edit the properties.

    • The number of output bands will remain as 3.
    • On the Band Source tab, enter the band combination in the first three parameter text boxes. Band Source-1 represents the red band, Band Source-2 represents the green band, and Band Source-3 represents the blue band. Therefore, to make a natural color band combination, you would use 3,2,1.
      Extract Bands dialog box

Build and compile the image service definition

As a final step, it is necessary to change the image service definition back to the original three-band service.

步骤:
  1. Click the Image Service drop-down arrow on the Image Service Definition Editor toolbar, point to Advanced, then click Build.
  2. Check Compute output pixel properties and Load preview.
  3. You may need to build service overviews.
  4. Compile the image service definition.

相关主题


7/10/2012