mirror of
https://github.com/haraldk/TwelveMonkeys.git
synced 2025-08-05 04:25:29 -04:00
TMI-77: Fixed bug in predictor for tiled TIFFs.
This commit is contained in:
parent
add6e07cae
commit
3c08cae093
@ -122,6 +122,14 @@ final class EXIFEntry extends AbstractEntry {
|
|||||||
return "HostComputer";
|
return "HostComputer";
|
||||||
case TIFF.TAG_PREDICTOR:
|
case TIFF.TAG_PREDICTOR:
|
||||||
return "Predictor";
|
return "Predictor";
|
||||||
|
case TIFF.TAG_TILE_WIDTH:
|
||||||
|
return "TileWidth";
|
||||||
|
case TIFF.TAG_TILE_HEIGTH:
|
||||||
|
return "TileHeight";
|
||||||
|
case TIFF.TAG_TILE_OFFSETS:
|
||||||
|
return "TileOffsets";
|
||||||
|
case TIFF.TAG_TILE_BYTE_COUNTS:
|
||||||
|
return "TileByteCounts";
|
||||||
case TIFF.TAG_COPYRIGHT:
|
case TIFF.TAG_COPYRIGHT:
|
||||||
return "Copyright";
|
return "Copyright";
|
||||||
case TIFF.TAG_YCBCR_SUB_SAMPLING:
|
case TIFF.TAG_YCBCR_SUB_SAMPLING:
|
||||||
|
@ -76,4 +76,11 @@ interface TIFFExtension {
|
|||||||
|
|
||||||
/** For use with Photometric: 5 (Separated), when image data is in CMYK color space. */
|
/** For use with Photometric: 5 (Separated), when image data is in CMYK color space. */
|
||||||
int INKSET_CMYK = 1;
|
int INKSET_CMYK = 1;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* For use with Photometric: 5 (Separated), when image data is in a color space other than CMYK.
|
||||||
|
* See {@link com.twelvemonkeys.imageio.metadata.exif.TIFF#TAG_INK_NAMES InkNames} field for a
|
||||||
|
* description of the inks to be used.
|
||||||
|
*/
|
||||||
|
int INKSET_NOT_CMYK = 2;
|
||||||
}
|
}
|
||||||
|
@ -665,8 +665,8 @@ public class TIFFImageReader extends ImageReaderBase {
|
|||||||
? IIOUtil.createStreamAdapter(imageInput, stripTileByteCounts[i])
|
? IIOUtil.createStreamAdapter(imageInput, stripTileByteCounts[i])
|
||||||
: IIOUtil.createStreamAdapter(imageInput);
|
: IIOUtil.createStreamAdapter(imageInput);
|
||||||
|
|
||||||
adapter = createDecompressorStream(compression, width, adapter);
|
adapter = createDecompressorStream(compression, stripTileWidth, adapter);
|
||||||
adapter = createUnpredictorStream(predictor, width, numBands, getBitsPerSample(), adapter, imageInput.getByteOrder());
|
adapter = createUnpredictorStream(predictor, stripTileWidth, numBands, getBitsPerSample(), adapter, imageInput.getByteOrder());
|
||||||
|
|
||||||
if (interpretation == TIFFExtension.PHOTOMETRIC_YCBCR && rowRaster.getTransferType() == DataBuffer.TYPE_BYTE) {
|
if (interpretation == TIFFExtension.PHOTOMETRIC_YCBCR && rowRaster.getTransferType() == DataBuffer.TYPE_BYTE) {
|
||||||
adapter = new YCbCrUpsamplerStream(adapter, yCbCrSubsampling, yCbCrPos, colsInTile, yCbCrCoefficients);
|
adapter = new YCbCrUpsamplerStream(adapter, yCbCrSubsampling, yCbCrPos, colsInTile, yCbCrCoefficients);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user