Class HorizontalDeDifferencingStream
java.lang.Object
java.io.InputStream
com.twelvemonkeys.imageio.plugins.psd.HorizontalDeDifferencingStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
A decoder for data converted using "horizontal differencing predictor".
- Version:
- $Id: HorizontalDeDifferencingStream.java,v 1.0 11.03.13 14:20 haraldk Exp$
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
private final ByteBuffer
private final ReadableByteChannel
private final int
private final int
-
Constructor Summary
ConstructorsConstructorDescriptionHorizontalDeDifferencingStream
(InputStream stream, int columns, int samplesPerPixel, int bitsPerSample, ByteOrder byteOrder) -
Method Summary
Methods inherited from class java.io.InputStream
available, mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skipNBytes, transferTo
-
Field Details
-
columns
private final int columns -
samplesPerPixel
private final int samplesPerPixel -
bitsPerSample
private final int bitsPerSample -
channel
-
buffer
-
-
Constructor Details
-
HorizontalDeDifferencingStream
public HorizontalDeDifferencingStream(InputStream stream, int columns, int samplesPerPixel, int bitsPerSample, ByteOrder byteOrder)
-
-
Method Details
-
isValidBPS
static boolean isValidBPS(int bitsPerSample) -
fetch
- Throws:
IOException
-
decodeRow
private void decodeRow() -
read
- Specified by:
read
in classInputStream
- Throws:
IOException
-
read
- Overrides:
read
in classInputStream
- Throws:
IOException
-
skip
- Overrides:
skip
in classInputStream
- Throws:
IOException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classInputStream
- Throws:
IOException
-