public class ImageDeltaCompressor extends Object
| Constructor and Description |
|---|
ImageDeltaCompressor() |
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
compressByRawBlocks(BufferedImage target,
byte[] targetEncoded,
BufferedImage source)
Compresses a target image based on a difference from a source image.
|
static byte[] |
compressByRawBlocks(BufferedImage target,
byte[] targetEncoded,
BufferedImage source,
int blockSize)
Compresses a target image based on a difference from a source image.
|
public static byte[] compressByRawBlocks(BufferedImage target, byte[] targetEncoded, BufferedImage source, int blockSize) throws IOException
target - The image we want to compress.targetEncoded - The image we want to compress in its png bytes
representation.source - The baseline image by which a compression will be
performed.blockSize - How many pixels per block.targetEncoded if the
compressed bytes count is greater than the uncompressed bytes count.IOException - If there was a problem reading/writing
from/to the streams which are created during the process.public static byte[] compressByRawBlocks(BufferedImage target, byte[] targetEncoded, BufferedImage source) throws IOException
blockSize defaults to 10.target - The image we want to compress.targetEncoded - The image we want to compress in its png bytes
representation.source - The baseline image by which a compression will be
performed.IOException - If there was a problem reading/writing
from/to the streams which are created during the process.Copyright © 2016. All rights reserved.