Reusable Java library of general tools with minimal external dependencies.
For questions or support, please contact us:
Email: support@aoindustries.com
Phone: 1-800-519-9541
Phone: +1-251-607-9556
Web: https://www.aoindustries.com/contact
public final class Images extends Object
| Modifier and Type | Method and Description |
|---|---|
static Point |
findImage(BufferedImage image,
BufferedImage findme,
double tolerance)
Finds one image within another.
|
static Point |
findImage(int[] imagePixels,
int imageWidth,
int imageHeight,
int[] findmePixels,
int findmeWidth,
int findmeHeight,
double tolerance)
Finds one image within another.
|
static Image |
getImageFromResources(Class<?> clazz,
String name)
Loads an image from a resource using the default toolkit.
|
static Image |
getImageFromResources(Class<?> clazz,
String name,
Toolkit toolkit)
Loads an image from a resource using the provided toolkit.
|
static int[] |
getRGB(BufferedImage image)
Gets the RGB pixels for the given image into a new array.
|
static void |
getRGB(BufferedImage image,
int[] pixels)
Gets the RGB pixels for the given image into the given array.
|
static int[] |
getRGBArray(BufferedImage image)
Gets an array big enough to hold the provided image pixels.
|
static int[] |
getRGBArray(Dimension size)
Gets an array big enough to hold the pixels for an image of the given size.
|
static int[] |
getRGBArray(int width,
int height)
Gets an array big enough to hold the pixels for an image of the given size.
|
public static int[] getRGBArray(int width,
int height)
public static int[] getRGBArray(Dimension size)
public static int[] getRGBArray(BufferedImage image)
public static int[] getRGB(BufferedImage image)
public static void getRGB(BufferedImage image, int[] pixels)
public static Point findImage(BufferedImage image, BufferedImage findme, double tolerance)
tolerance - The portion of red, green, and blue differences
allowed before ignoring a certain location. Zero implies
an exact match.null if not found within tolerance.public static Point findImage(int[] imagePixels, int imageWidth, int imageHeight, int[] findmePixels, int findmeWidth, int findmeHeight, double tolerance)
tolerance - The portion of red, green, and blue differences
allowed before ignoring a certain location. Zero implies
an exact match.null if not found within tolerance.public static Image getImageFromResources(Class<?> clazz, String name) throws IOException
IOExceptionpublic static Image getImageFromResources(Class<?> clazz, String name, Toolkit toolkit) throws IOException
IOExceptionCopyright © 2000–2016 AO Industries, Inc.. All rights reserved.