|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.ngs.image.filter.BrightnessContrastOp
public class BrightnessContrastOp
Java-Only implementation that handles Brightness, Contrast, and Invert via lookup-table manipulation of ColorModels. This is included for completness, and is probably most beneficial to those individuals looking to learn about lower-level Image handling & manipulation.
This class is unused by the core Shimaging ImagePanel, but may be usefull in some cases. Shimaging uses RescaleOp & LookupOp to implement it's contrast, brightness, and invert operations. These J2SE standard filters are often accelerated by ImageLib native implementations.
| Constructor Summary | |
|---|---|
BrightnessContrastOp(int brightness,
float contrast,
RenderingHints hints)
Creates a new Brightness & Contrast Operation with the given brightness, contrast, and rendering hints. |
|
BrightnessContrastOp(RenderingHints hints)
Creates a new Brightness & Contrast Operation. |
|
| Method Summary | |
|---|---|
BufferedImage |
createCompatibleDestImage(BufferedImage src,
ColorModel destCM)
|
WritableRaster |
createCompatibleDestRaster(Raster src)
|
BufferedImage |
filter(BufferedImage src,
BufferedImage dst)
|
WritableRaster |
filter(Raster src,
WritableRaster dst)
|
Rectangle2D |
getBounds2D(BufferedImage src)
|
Rectangle2D |
getBounds2D(Raster src)
|
int |
getBrightness()
|
float |
getContrast()
|
boolean |
getInvert()
|
Point2D |
getPoint2D(Point2D srcPt,
Point2D dstPt)
|
RenderingHints |
getRenderingHints()
|
void |
setBrightness(int brightness)
Sets the brightness used when filtering. |
void |
setContrast(float contrast)
Sets the contrast used when filtering. |
void |
setInvert(boolean invert)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BrightnessContrastOp(RenderingHints hints)
public BrightnessContrastOp(int brightness,
float contrast,
RenderingHints hints)
| Method Detail |
|---|
public void setBrightness(int brightness)
public void setContrast(float contrast)
public int getBrightness()
public float getContrast()
public boolean getInvert()
public void setInvert(boolean invert)
public BufferedImage createCompatibleDestImage(BufferedImage src,
ColorModel destCM)
createCompatibleDestImage in interface BufferedImageOppublic WritableRaster createCompatibleDestRaster(Raster src)
createCompatibleDestRaster in interface RasterOppublic Rectangle2D getBounds2D(BufferedImage src)
getBounds2D in interface BufferedImageOppublic Rectangle2D getBounds2D(Raster src)
getBounds2D in interface RasterOp
public Point2D getPoint2D(Point2D srcPt,
Point2D dstPt)
getPoint2D in interface BufferedImageOpgetPoint2D in interface RasterOppublic RenderingHints getRenderingHints()
getRenderingHints in interface BufferedImageOpgetRenderingHints in interface RasterOp
public BufferedImage filter(BufferedImage src,
BufferedImage dst)
filter in interface BufferedImageOp
public WritableRaster filter(Raster src,
WritableRaster dst)
filter in interface RasterOp
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||