org.salespointframework.desktop.imagefilter
Class LinearFadeFilter

java.lang.Object
  extended by java.awt.image.ImageFilter
      extended by java.awt.image.RGBImageFilter
          extended by org.salespointframework.desktop.imagefilter.LinearFadeFilter
All Implemented Interfaces:
java.awt.image.ImageConsumer, java.lang.Cloneable

public class LinearFadeFilter
extends java.awt.image.RGBImageFilter

performs a linear fade on the image

Since:
4.0
Author:
Thomas Kissinger

Nested Class Summary
static class LinearFadeFilter.FadeDirection
           
 
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 java.awt.image.ImageConsumer
COMPLETESCANLINES, IMAGEABORTED, IMAGEERROR, RANDOMPIXELORDER, SINGLEFRAME, SINGLEFRAMEDONE, SINGLEPASS, STATICIMAGEDONE, TOPDOWNLEFTRIGHT
 
Constructor Summary
LinearFadeFilter(int height)
          default constructor
LinearFadeFilter(int height, int totalHeight, LinearFadeFilter.FadeDirection direction, float alpha1, float alpha2)
          constructor
 
Method Summary
 int filterRGB(int x, int y, int rgb)
           
 
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

LinearFadeFilter

public LinearFadeFilter(int height)
default constructor

Parameters:
height - image height

LinearFadeFilter

public LinearFadeFilter(int height,
                        int totalHeight,
                        LinearFadeFilter.FadeDirection direction,
                        float alpha1,
                        float alpha2)
constructor

Parameters:
height - fading height
totalHeight - image height
direction -
alpha1 - from
alpha2 - to
Method Detail

filterRGB

public int filterRGB(int x,
                     int y,
                     int rgb)
Specified by:
filterRGB in class java.awt.image.RGBImageFilter