Class ssfd.ICMFilter
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ssfd.ICMFilter

java.lang.Object
   |
   +----java.awt.image.ImageFilter
           |
           +----java.awt.image.RGBImageFilter
                   |
                   +----ssfd.ICMFilter

public class ICMFilter
extends RGBImageFilter
Uses an integer parameter to select a color in an IndexColorModel (hence the name of the class) that will be used to replace every "color" (a pixel with a nonzero saturation). Other pixels are made transparent.
Version:
1.0 02-20-97
Author:
Daren Stotler
See Also:
RGBImageFilter

Constructor Index

 o ICMFilter(int, IndexColorModel)
Grabs the input parameters and initializes the corresponding instance variables.

Method Index

 o filterRGB(int, int, int)
Checks the saturation of the input color.

Constructors

 o ICMFilter
  public ICMFilter(int pv,
                   IndexColorModel icm)
Grabs the input parameters and initializes the corresponding instance variables. Also, lets the superclass know that the filter only cares about the color of a pixel, and not about where in the image it's located.
Parameters:
pv - integer which will be used as an index into the color model
icm - that color model

Methods

 o filterRGB
  public int filterRGB(int x,
                       int y,
                       int rgb)
Checks the saturation of the input color. If nonzero, changes the color to that selected by the index and the color model sent to the constructor.
Parameters:
x - horizontal location of the pixel (not used)
y - vertical location of the pixel (not used)
rgb - color of the pixel being filtered
Overrides:
filterRGB in class RGBImageFilter

All Packages  Class Hierarchy  This Package  Previous  Next  Index