40 lines
1.5 KiB
Diff
40 lines
1.5 KiB
Diff
|
Index: ImageMagick-6.6.1-0/coders/tiff.c
|
||
|
===================================================================
|
||
|
--- ImageMagick-6.6.1-0.orig/coders/tiff.c
|
||
|
+++ ImageMagick-6.6.1-0/coders/tiff.c
|
||
|
@@ -2668,22 +2668,19 @@ static MagickBooleanType WriteTIFFImage(
|
||
|
image->endian=MSBEndian;
|
||
|
if ((int) (*(char *) &lsb_first) != 0)
|
||
|
image->endian=LSBEndian;
|
||
|
- if ((compress_tag == COMPRESSION_JPEG) && (photometric != PHOTOMETRIC_RGB))
|
||
|
- compress_tag=COMPRESSION_NONE;
|
||
|
+ if ((compress_tag == COMPRESSION_CCITTFAX3) &&
|
||
|
+ (photometric != PHOTOMETRIC_MINISWHITE))
|
||
|
+ {
|
||
|
+ compress_tag=COMPRESSION_NONE;
|
||
|
+ endian=FILLORDER_MSB2LSB;
|
||
|
+ }
|
||
|
else
|
||
|
- if ((compress_tag == COMPRESSION_CCITTFAX3) &&
|
||
|
- (photometric != PHOTOMETRIC_MINISWHITE))
|
||
|
- {
|
||
|
- compress_tag=COMPRESSION_NONE;
|
||
|
- endian=FILLORDER_MSB2LSB;
|
||
|
- }
|
||
|
- else
|
||
|
- if ((compress_tag == COMPRESSION_CCITTFAX4) &&
|
||
|
- (photometric != PHOTOMETRIC_MINISWHITE))
|
||
|
- {
|
||
|
- compress_tag=COMPRESSION_NONE;
|
||
|
- endian=FILLORDER_MSB2LSB;
|
||
|
- }
|
||
|
+ if ((compress_tag == COMPRESSION_CCITTFAX4) &&
|
||
|
+ (photometric != PHOTOMETRIC_MINISWHITE))
|
||
|
+ {
|
||
|
+ compress_tag=COMPRESSION_NONE;
|
||
|
+ endian=FILLORDER_MSB2LSB;
|
||
|
+ }
|
||
|
(void) TIFFSetField(tiff,TIFFTAG_COMPRESSION,compress_tag);
|
||
|
(void) TIFFSetField(tiff,TIFFTAG_FILLORDER,endian);
|
||
|
(void) TIFFSetField(tiff,TIFFTAG_BITSPERSAMPLE,quantum_info->depth);
|