APIdia Launch Partner
Top Fields Constructors Methods
com.sun.imageio.plugins.tiff

pack-priv Class TIFFLZWDecompressor

extends TIFFDecompressor
Class Inheritance
Imports
java.io.IOException, javax.imageio.IIOException, javax.imageio.plugins.tiff.BaselineTIFFTagSet, com.sun.imageio.plugins.common.ReaderUtil

Field Summary

Modifier and TypeField and Description
private static final int[]
private int
private static final int
private byte[]
private int
private static final int
private static final int
private boolean
private int
private int
private int
private byte[]
private int
private byte[][]
private int
Inherited from com.sun.imageio.plugins.tiff.TIFFDecompressor:
activeSrcHeightactiveSrcMinXactiveSrcMinYactiveSrcWidthbitsPerSamplebyteCountcolorConvertercolorMapcompressiondestinationBandsdstHeightdstMinXdstMinYdstWidthdstXOffsetdstYOffsetextraSamplesimagemetadataoffsetphotometricInterpretationplanarplanarBandrawImagereadersampleFormatsamplesPerPixelsourceBandssourceXOffsetsourceYOffsetsrcHeightsrcMinXsrcMinYsrcWidthstreamsubsampleXsubsampleY

Constructor Summary

AccessConstructor and Description
public
TIFFLZWDecompressor(int predictor, int fillOrder)

Method Summary

Modifier and TypeMethod and Description
public void
addStringToTable(byte[] oldString, byte newString)

Add a new string to the string table.

public void
addStringToTable(byte[] string)

Add a new string to the string table.

public byte[]
composeString(byte[] oldString, byte newString)

Append newString to the end of oldString.

public int
decode(byte[] sdata, int srcOffset, byte[] ddata, int dstOffset)

public void
decodeRaw(byte[] b, int dstOffset, int bitsPerPixel, int scanlineStride)

Implements abstract com.sun.imageio.plugins.tiff.TIFFDecompressor.decodeRaw.

Decodes the source data into the provided byte array b, starting at the offset given by dstOffset.

public int
public void
initializeStringTable()

Initialize the string table.

public void
writeString(byte[] string)

Write out the string just uncompressed.

Inherited from com.sun.imageio.plugins.tiff.TIFFDecompressor:
beginDecodingcreateComponentCMcreateInterleavedSMcreateRawImagedecodedecodeRawdecodeRawdecodeRawdecodeRawgetRawImageTypegetRawImageTypeSpecifiersetActiveSrcHeightsetActiveSrcMinXsetActiveSrcMinYsetActiveSrcWidthsetBitsPerSamplesetByteCountsetColorConvertersetColorMapsetCompressionsetDestinationBandssetDstHeightsetDstMinXsetDstMinYsetDstWidthsetDstXOffsetsetDstYOffsetsetExtraSamplessetImagesetMetadatasetOffsetsetPhotometricInterpretationsetPlanarsetPlanarBandsetReadersetSampleFormatsetSamplesPerPixelsetSourceBandssetSourceXOffsetsetSourceYOffsetsetSrcHeightsetSrcMinXsetSrcMinYsetSrcWidthsetStreamsetSubsampleXsetSubsampleY

Field Detail

andTableback to summary
private static final int[] andTable
bitsToGetback to summary
private int bitsToGet
CLEAR_CODEback to summary
private static final int CLEAR_CODE
dstDataback to summary
private byte[] dstData
dstIndexback to summary
private int dstIndex
EOI_CODEback to summary
private static final int EOI_CODE
FIRST_CODEback to summary
private static final int FIRST_CODE
flipBitsback to summary
private boolean flipBits
nextBitsback to summary
private int nextBits
nextDataback to summary
private int nextData
predictorback to summary
private int predictor
srcDataback to summary
private byte[] srcData
srcIndexback to summary
private int srcIndex
stringTableback to summary
private byte[][] stringTable
tableIndexback to summary
private int tableIndex

Constructor Detail

TIFFLZWDecompressorback to summary
public TIFFLZWDecompressor(int predictor, int fillOrder) throws IIOException

Method Detail

addStringToTableback to summary
public void addStringToTable(byte[] oldString, byte newString)

Add a new string to the string table.

addStringToTableback to summary
public void addStringToTable(byte[] string)

Add a new string to the string table.

composeStringback to summary
public byte[] composeString(byte[] oldString, byte newString)

Append newString to the end of oldString.

decodeback to summary
public int decode(byte[] sdata, int srcOffset, byte[] ddata, int dstOffset) throws IOException
decodeRawback to summary
public void decodeRaw(byte[] b, int dstOffset, int bitsPerPixel, int scanlineStride) throws IOException

Implements abstract com.sun.imageio.plugins.tiff.TIFFDecompressor.decodeRaw.

Doc from com.sun.imageio.plugins.tiff.TIFFDecompressor.decodeRaw.

Decodes the source data into the provided byte array b, starting at the offset given by dstOffset. Each pixel occupies bitsPerPixel bits, with no padding between pixels. Scanlines are separated by scanlineStride bytes.

Annotations
@Override
Exceptions
IOException:
if an error occurs reading from the source ImageInputStream.
getNextCodeback to summary
public int getNextCode()
initializeStringTableback to summary
public void initializeStringTable()

Initialize the string table.

writeStringback to summary
public void writeString(byte[] string)

Write out the string just uncompressed.