public final class MatrixToImageWriter extends Object
BitMatrix to BufferedImage,
file or stream. Provided here instead of core since it depends on
Java SE libraries.| Modifier and Type | Method and Description |
|---|---|
static BufferedImage |
toBufferedImage(BitMatrix matrix)
Renders a
BitMatrix as an image, where "false" bits are rendered
as white, and "true" bits are rendered as black. |
static BufferedImage |
toBufferedImage(BitMatrix matrix,
MatrixToImageConfig config)
As
toBufferedImage(BitMatrix), but allows customization of the output. |
static void |
writeToFile(BitMatrix matrix,
String format,
File file)
Deprecated.
|
static void |
writeToFile(BitMatrix matrix,
String format,
File file,
MatrixToImageConfig config)
Deprecated.
|
static void |
writeToPath(BitMatrix matrix,
String format,
java.nio.file.Path file)
Writes a
BitMatrix to a file. |
static void |
writeToPath(BitMatrix matrix,
String format,
java.nio.file.Path file,
MatrixToImageConfig config)
As
writeToFile(BitMatrix, String, File), but allows customization of the output. |
static void |
writeToStream(BitMatrix matrix,
String format,
OutputStream stream)
Writes a
BitMatrix to a stream. |
static void |
writeToStream(BitMatrix matrix,
String format,
OutputStream stream,
MatrixToImageConfig config)
As
writeToStream(BitMatrix, String, OutputStream), but allows customization of the output. |
public static BufferedImage toBufferedImage(BitMatrix matrix)
BitMatrix as an image, where "false" bits are rendered
as white, and "true" bits are rendered as black.public static BufferedImage toBufferedImage(BitMatrix matrix, MatrixToImageConfig config)
toBufferedImage(BitMatrix), but allows customization of the output.@Deprecated public static void writeToFile(BitMatrix matrix, String format, File file) throws IOException
writeToPath(BitMatrix, String, Path)IOExceptionpublic static void writeToPath(BitMatrix matrix, String format, java.nio.file.Path file) throws IOException
BitMatrix to a file.IOExceptiontoBufferedImage(BitMatrix)@Deprecated public static void writeToFile(BitMatrix matrix, String format, File file, MatrixToImageConfig config) throws IOException
writeToPath(BitMatrix, String, Path, MatrixToImageConfig)IOExceptionpublic static void writeToPath(BitMatrix matrix, String format, java.nio.file.Path file, MatrixToImageConfig config) throws IOException
writeToFile(BitMatrix, String, File), but allows customization of the output.IOExceptionpublic static void writeToStream(BitMatrix matrix, String format, OutputStream stream) throws IOException
BitMatrix to a stream.IOExceptiontoBufferedImage(BitMatrix)public static void writeToStream(BitMatrix matrix, String format, OutputStream stream, MatrixToImageConfig config) throws IOException
writeToStream(BitMatrix, String, OutputStream), but allows customization of the output.IOExceptionCopyright © 2007-2014. All Rights Reserved.