|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectutils.ImageUtils
public class ImageUtils
This class provides various methods that help with the image processing tasks
| Constructor Summary | |
|---|---|
ImageUtils()
|
|
| Method Summary | |
|---|---|
static java.awt.image.BufferedImage |
applyBlending(java.awt.image.BufferedImage image,
java.awt.Composite compositeToUse,
int red,
int green,
int blue)
Apply the desired blending to the given image with the given color |
static org.eclipse.swt.graphics.ImageData |
applyBlendingSWT(java.awt.image.BufferedImage image,
java.awt.Composite compositeToUse,
int red,
int green,
int blue)
Apply the desired blending to the given image with the given color |
static java.awt.image.BufferedImage |
convertToAWT(org.eclipse.swt.graphics.ImageData data)
Converts a given SWT ImageData into a AWT BufferedImage |
static org.eclipse.swt.graphics.ImageData |
convertToSWT(java.awt.image.BufferedImage awt)
Converts a given AWT BufferedImage into a SWT ImageData |
static java.awt.image.BufferedImage |
createSoftClipping(java.awt.image.BufferedImage sourceImage,
java.awt.Shape clippingShape)
Create a soft clipped image of a given image using a given clipping shape |
static double |
getResizingRatio(java.awt.image.BufferedImage image,
int desiredWidth,
int desiredHeight)
Returns the resizing ratio that is needed to scale the given image so that will fit inside the desired dimension with at least one of it's length (width/height) equal to given one. |
static double |
getResizingRatio(double imageWidth,
double imageHeight,
int desiredWidth,
int desiredHeight)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ImageUtils()
| Method Detail |
|---|
public static org.eclipse.swt.graphics.ImageData applyBlendingSWT(java.awt.image.BufferedImage image,
java.awt.Composite compositeToUse,
int red,
int green,
int blue)
image - the source image for the blendingcompositeToUse - the composite to be used by the blendingred - an 0-255 INT value for the red channelgreen - an 0-255 INT value for the green channelblue - an 0-255 INT value for the blue channel
public static java.awt.image.BufferedImage applyBlending(java.awt.image.BufferedImage image,
java.awt.Composite compositeToUse,
int red,
int green,
int blue)
image - the source image for the blendingcompositeToUse - the composite to be used by the blendingred - an 0-255 INT value for the red channelgreen - an 0-255 INT value for the green channelblue - an 0-255 INT value for the blue channel
public static java.awt.image.BufferedImage convertToAWT(org.eclipse.swt.graphics.ImageData data)
ImageData into a AWT BufferedImage
data - the SWT image data
public static final org.eclipse.swt.graphics.ImageData convertToSWT(java.awt.image.BufferedImage awt)
BufferedImage into a SWT ImageData
awt - the AWT buffered image
public static double getResizingRatio(java.awt.image.BufferedImage image,
int desiredWidth,
int desiredHeight)
image - the source imagedesiredWidth - the desired width of the given imagedesiredHeight - the desired height of the given image
public static double getResizingRatio(double imageWidth,
double imageHeight,
int desiredWidth,
int desiredHeight)
public static java.awt.image.BufferedImage createSoftClipping(java.awt.image.BufferedImage sourceImage,
java.awt.Shape clippingShape)
sourceImage - the image from which clipping will be createdclippingShape - the shape used to do the clipping
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||