public class ImageExtractor
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
ImageExtractor.BmpFileReader
Helps to extract an image encoded according to bitmap file format (BMP):
BITMAPFILEHEADER stores general information about the bitmap image
BITMAPINFOHEADER stores image details, defines the pixel format
RGBGUAD[] stores the color table
BYTE[] stores the pixel data
|
static class |
ImageExtractor.GifFileReader
Helps to extract an image encoded according to Graphics Interchange Format file format (GIF):
http://giflib.sourceforge.net/whatsinagif/bits_and_bytes.html
GIF Specification:
http://giflib.sourceforge.net/gifstandard/GIF89a.html
|
static interface |
ImageExtractor.ImageReader
Defines public methods for image readers.
|
static class |
ImageExtractor.ImageReaderAdapter
Adapts image readers to read different image types from the common data source.
|
Modifier | Constructor and Description |
---|---|
private |
ImageExtractor()
Provides only static methods to extract images from data streams.
|
Modifier and Type | Method and Description |
---|---|
static void |
extractAllImages(java.io.RandomAccessFile raf,
ImageExtractor.ImageReader imageReader,
java.lang.String dir,
java.lang.String prefix)
Extract all target images from the given file.
|
static void |
extractSequentiallyAllImages(java.io.RandomAccessFile raf,
java.util.List<ImageExtractor.ImageReader> imageReaders,
java.lang.String dir,
java.lang.String prefix)
Extract sequentially all supported images from the given file.
|
private ImageExtractor()
public static void extractAllImages(java.io.RandomAccessFile raf, ImageExtractor.ImageReader imageReader, java.lang.String dir, java.lang.String prefix) throws java.io.IOException
raf
- The given fileimageReader
- The image readerdir
- The output directoryprefix
- The prefix used as a name template for extracted image files.java.io.IOException
public static void extractSequentiallyAllImages(java.io.RandomAccessFile raf, java.util.List<ImageExtractor.ImageReader> imageReaders, java.lang.String dir, java.lang.String prefix) throws java.io.IOException
raf
- The given fileimageReaders
- The list of an image readerdir
- The output directoryprefix
- The prefix used as a name template for extracted image files.java.io.IOException