public class ChunkCopyBehaviour extends Object
PngReader
to a PngWriter
.
The constants are bit-masks, they can be OR-ed
Reference: http://www.w3.org/TR/PNG/#14
Modifier and Type | Field and Description |
---|---|
static int |
COPY_ALL
copy all, including palette
|
static int |
COPY_ALL_SAFE
copy all 'safe to copy' chunks
|
static int |
COPY_ALMOSTALL
Copy almost all: excepts only HIST (histogram) TIME and TEXTUAL chunks
|
static int |
COPY_NONE
Don't copy anything
|
static int |
COPY_PALETTE
copy the palette
|
static int |
COPY_PHYS
Copy PHYS chunk (physical resolution)
|
static int |
COPY_TEXTUAL
Copy al textual chunks.
|
static int |
COPY_TRANSPARENCY
Copy TRNS chunk
|
static int |
COPY_UNKNOWN
Copy unknown chunks (unknown by our factory)
|
Constructor and Description |
---|
ChunkCopyBehaviour() |
Modifier and Type | Method and Description |
---|---|
static ChunkPredicate |
createPredicate(int copyFromMask,
ImageInfo imgInfo)
Creates a predicate equivalent to the copy mask
|
public static final int COPY_NONE
public static final int COPY_PALETTE
public static final int COPY_ALL_SAFE
public static final int COPY_ALL
public static final int COPY_PHYS
public static final int COPY_TEXTUAL
public static final int COPY_TRANSPARENCY
public static final int COPY_UNKNOWN
public static final int COPY_ALMOSTALL
public static ChunkPredicate createPredicate(int copyFromMask, ImageInfo imgInfo)
Given a copy mask (see static fields) and the ImageInfo of the target PNG, returns a predicate that tells if a chunk should be copied.
This is a handy helper method, you can also create and set your own predicate
Copyright © 2014. All rights reserved.