SpectralConversion

Summary

Applies a matrix to a multiband image to affect the color values of the output.

Discussion

For more information about how this function works, see the Spectral Conversion raster function.

The referenced raster dataset for the raster object is temporary. To make it permanent, you can call the raster object's save method.

Syntax

SpectralConversion (raster, conversion_matrix)
ParameterExplanationData Type
raster

The input raster.

This can be a raster dataset within a mosaic dataset or raster catalog, or a raster dataset outside the mosaic dataset.

Raster
conversion_matrix

The matrix used to convert the input raster.

The equation used to perform this conversion is as follows:

Output Band_R = Weight_P * Band_C

where:

  • Band_R is an output band, where R is a number from 1 to the number of output bands.
  • Weight_P is a comma-delimited list of weights, 1 for each input band. The sum of the weights for each band should equal 1.
  • Band_C is the input image, where C is a number from 1 to the number of bands of the input image.

Raster
Return Value
Data TypeExplanation
Raster

The output raster.


In this topic