public abstract class TIFFFaxCompressor extends TIFFCompressor
Modifier and Type | Field and Description |
---|---|
int |
bits
Output bit buffer.
|
static int |
BLACK
The CCITT numerical definition of black.
|
static byte[] |
byteTable |
static int[][] |
horz
Black and white horizontal mode table.
|
static int[] |
horzMode
Horizontal mode table.
|
boolean |
inverseFill
Whether bits are inserted in reverse order (TIFF FillOrder 2).
|
static int[][] |
makeupCodes
Black and white make-up code table.
|
static int[] |
makeupCodesBlack
Make-up codes for black runs.
|
static int[] |
makeupCodesWhite
Make-up codes for white runs.
|
int |
ndex
Number of bits in the output bit buffer.
|
static int[][] |
pass
Black and white pass mode table.
|
static int[] |
passMode
Pass mode table.
|
static int[][] |
termCodes
Black and white terminating code table.
|
static int[] |
termCodesBlack
Terminating codes for black runs.
|
static int[] |
termCodesWhite
Terminating codes for white runs.
|
static int[][] |
vert
Black and white vertical mode table.
|
static int[] |
vertMode
Vertical mode table.
|
static int |
WHITE
The CCITT numerical definition of white.
|
compressionTagValue, compressionType, isCompressionLossless, metadata, stream, writer
Modifier | Constructor and Description |
---|---|
protected |
TIFFFaxCompressor(String compressionType,
int compressionTagValue,
boolean isCompressionLossless)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
add1DBits(byte[] buf,
int where,
int count,
int color)
Get code for run and add to compressed bitstream.
|
int |
add2DBits(byte[] buf,
int where,
int[][] mode,
int entry)
Place entry from mode table into compressed bitstream.
|
int |
addEOFB(byte[] buf,
int where)
Add an End-of-Facsimile-Block (EOFB == 0x001001) to the compressed
bitstream.
|
int |
addEOL(boolean is1DMode,
boolean addFill,
boolean add1,
byte[] buf,
int where)
Add an End-of-Line (EOL == 0x001) to the compressed bitstream
with optional byte alignment.
|
int |
encode1D(byte[] data,
int rowOffset,
int colOffset,
int rowLength,
byte[] compData,
int compOffset)
One-dimensionally encode a row of data using CCITT Huffman compression.
|
void |
initBitBuf()
Initialize bit buffer machinery.
|
int |
nextState(byte[] data,
int base,
int bitOffset,
int maxOffset)
Return min of
maxOffset or offset of first pixel
different from pixel at bitOffset . |
void |
setMetadata(IIOMetadata metadata)
Sets the value of the
metadata field. |
encode, getCompressionTagValue, getCompressionType, getMetadata, getStream, getWriter, isCompressionLossless, setStream, setWriter
public static final int WHITE
public static final int BLACK
public static byte[] byteTable
public static int[] termCodesBlack
public static int[] termCodesWhite
public static int[] makeupCodesBlack
public static int[] makeupCodesWhite
public static int[] passMode
public static int[] vertMode
public static int[] horzMode
public static int[][] termCodes
public static int[][] makeupCodes
public static int[][] pass
public static int[][] vert
public static int[][] horz
public boolean inverseFill
public int bits
public int ndex
protected TIFFFaxCompressor(String compressionType, int compressionTagValue, boolean isCompressionLossless)
public void setMetadata(IIOMetadata metadata)
metadata
field.
The implementation in this class also sets local options from the FILL_ORDER field if it exists.
setMetadata
in class TIFFCompressor
metadata
- the IIOMetadata
object for the
image being written.TIFFCompressor.getMetadata()
public int nextState(byte[] data, int base, int bitOffset, int maxOffset)
maxOffset
or offset of first pixel
different from pixel at bitOffset
.public void initBitBuf()
public int add1DBits(byte[] buf, int where, int count, int color)
public int add2DBits(byte[] buf, int where, int[][] mode, int entry)
public int addEOL(boolean is1DMode, boolean addFill, boolean add1, byte[] buf, int where)
public int addEOFB(byte[] buf, int where)
public int encode1D(byte[] data, int rowOffset, int colOffset, int rowLength, byte[] compData, int compOffset)
Copyright © 2014 Open Microscopy Environment