cynosurex.image
Class GrayScaleFilter

java.lang.Object
  extended by java.awt.image.ImageFilter
      extended by java.awt.image.RGBImageFilter
          extended by cynosurex.image.GrayScaleFilter
All Implemented Interfaces:
cynosurex.internal.AuthorCommon, cynosurex.internal.CommonInterface, cynosurex.internal.CompanyCommon, java.awt.image.ImageConsumer, java.lang.Cloneable

public class GrayScaleFilter
extends java.awt.image.RGBImageFilter
implements cynosurex.internal.CommonInterface

The GrayScaleFilter class is used to filter a color image to gray-scale.

Version:
1.0, 7/30/1997
Author:
Chieh Cheng

Field Summary
 
Fields inherited from class java.awt.image.RGBImageFilter
canFilterIndexColorModel, newmodel, origmodel
 
Fields inherited from class java.awt.image.ImageFilter
consumer
 
Fields inherited from interface cynosurex.internal.CommonInterface
copyright, copyrightYears, notice, program, version
 
Fields inherited from interface cynosurex.internal.AuthorCommon
author, copyrightSymbol, noticeMsg, rights
 
Fields inherited from interface cynosurex.internal.CompanyCommon
company, email, website
 
Fields inherited from interface java.awt.image.ImageConsumer
COMPLETESCANLINES, IMAGEABORTED, IMAGEERROR, RANDOMPIXELORDER, SINGLEFRAME, SINGLEFRAMEDONE, SINGLEPASS, STATICIMAGEDONE, TOPDOWNLEFTRIGHT
 
Constructor Summary
GrayScaleFilter()
          Constructor to instructor that this class is position independent, so as to provide optimization.
 
Method Summary
 int filterRGB(int x, int y, int rgb)
          This method is called to filter the image.
 
Methods inherited from class java.awt.image.RGBImageFilter
filterIndexColorModel, filterRGBPixels, setColorModel, setPixels, setPixels, substituteColorModel
 
Methods inherited from class java.awt.image.ImageFilter
clone, getFilterInstance, imageComplete, resendTopDownLeftRight, setDimensions, setHints, setProperties
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GrayScaleFilter

public GrayScaleFilter()
Constructor to instructor that this class is position independent, so as to provide optimization.

Method Detail

filterRGB

public int filterRGB(int x,
                     int y,
                     int rgb)
This method is called to filter the image.

Specified by:
filterRGB in class java.awt.image.RGBImageFilter