com.esri.arcgis.datasourcesraster
Interface IPixelFilter

All Superinterfaces:
Serializable
All Known Implementing Classes:
BackgroundFilter, ClipFilter, ColormapFilter, FocalMeanFilter, FocalStatisticsFilter, LutFilter, MultibandFilter, NoDataFilter, PansharpeningFilter, PixelFilterCollection, RasterConvolutionFilter, RemapFilter

public interface IPixelFilter
extends Serializable

Provides access to members that control a pixel filter.

Description

IPixelFilter defines a simple pixel block filtering operation, which filters (changes) pixel values in place, and does not change pixel type. All rasters support IPixelOperation, which allows getting and setting of a pixel filter on a raster. Once set, the pixel filter will be applied, on IRaster::Read(), to the pixel block after it's read and right before it's returned.

Many local operations, where the output pixel value only depends on the current pixel, and focal operations, where pixels within a small neighborhood are involved to generate an output value, can be modeled as pixel filters. Remapping pixel values, applying a log() function, and etc are examples of local pixel filters. Calculating slope and aspect, image enhancement, and etc are examples of focal pixel filters.

ArcGIS provides many predefined pixel filters, including Lookup Table filter (LutFilter), Remap filter (RemapFilter), Convolution filter (RasterConvolutionFilter), Pansharpening filter (PansharpeningFilter), and etc.

IPixelFilter is designed for writing custom pixel filters. A custom pixel filter will implement IPixelFilter, and provide the size, IPixelFilter::GetSize(), and the center, IPixelFilter::GetCenterPosition(), of the filter moving window (neighborhood). The actual filtering is done inside IPixelFilter::Filter() where a pixel block passes in input pixel data, and carries out output pixel values. IPixelFilter::Filter() is responsible for setting both pixel values, and NoData bit mask. Raster is responsible for applying a custom pixel filter when a pixel block is read. Raster will read extra rows and columns on the borders, if necessary, pass the pixel block into the pixel filter, clip extra rows and columns, and finally set NoData values according to NoData bit mask.

Remarks

IPixleFilter filters the values of a raster using a pixelfilter.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

See Also:
IPixelOperation, IPixelFilterCollection

Method Summary
 void filter(IPixelBlock pBlock)
          Filters a pixel block.
 void getCenterPosition(int[] atColumn, int[] atRow)
          Gets center position of the filter.
 void getSize(int[] columns, int[] rows)
          Gets dimension of the filter.
 

Method Detail

getSize

void getSize(int[] columns,
             int[] rows)
             throws IOException,
                    AutomationException
Gets dimension of the filter.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
columns - The columns (in/out: use single element array)
rows - The rows (in/out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCenterPosition

void getCenterPosition(int[] atColumn,
                       int[] atRow)
                       throws IOException,
                              AutomationException
Gets center position of the filter.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
atColumn - The atColumn (in/out: use single element array)
atRow - The atRow (in/out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

filter

void filter(IPixelBlock pBlock)
            throws IOException,
                   AutomationException
Filters a pixel block.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
pBlock - A reference to a com.esri.arcgis.geodatabase.IPixelBlock (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.