1 /* 2 Configuration defines for installed libtiff. 3 This file maintained for backward compatibility. Do not use definitions 4 from this file in your programs. 5 */ 6 7 #ifndef _TIFFCONF_ 8 #define _TIFFCONF_ 9 10 /* The size of a `int', as computed by sizeof. */ 11 #define SIZEOF_INT 4 12 13 /* The size of a `long', as computed by sizeof. */ 14 #include <limits.h> 15 #if (LONG_MAX == +9223372036854775807L) 16 #define SIZEOF_LONG 8 17 #define SIZEOF_UNSIGNED_LONG 8 18 #elif (LONG_MAX == +2147483647) 19 #define SIZEOF_LONG 4 20 #define SIZEOF_UNSIGNED_LONG 4 21 #else 22 #error "Cannot detect SIZEOF_LONG" 23 #endif 24 25 /* Signed 8-bit type */ 26 #define TIFF_INT8_T signed char 27 28 /* Unsigned 8-bit type */ 29 #define TIFF_UINT8_T unsigned char 30 31 /* Signed 16-bit type */ 32 #define TIFF_INT16_T signed short 33 34 /* Unsigned 16-bit type */ 35 #define TIFF_UINT16_T unsigned short 36 37 /* Signed 32-bit type */ 38 #define TIFF_INT32_T signed int 39 40 /* Unsigned 32-bit type */ 41 #define TIFF_UINT32_T unsigned int 42 43 /* Signed / Unsigned 64-bit type */ 44 #ifdef _MSC_VER 45 #define TIFF_INT64_T signed __int64 46 #define TIFF_UINT64_T unsigned __int64 47 #else 48 #include <inttypes.h> 49 #define TIFF_INT64_T int64_t 50 #define TIFF_UINT64_T uint64_t 51 #endif // _MSC_VER 52 53 /* Signed 64-bit type */ 54 #if defined(_WIN64) 55 #define TIFF_SSIZE_T signed __int64 56 #else 57 #define TIFF_SSIZE_T signed long 58 #endif 59 60 /* Pointer difference type */ 61 #define TIFF_PTRDIFF_T ptrdiff_t 62 63 /* Compatibility stuff. */ 64 65 /* Define as 0 or 1 according to the floating point format suported by the 66 machine */ 67 #define HAVE_IEEEFP 1 68 69 /* 70 ----------------------------------------------------------------------- 71 Byte order 72 ----------------------------------------------------------------------- 73 */ 74 75 /* 76 Define WORDS_BIGENDIAN to 1 if your processor stores words with the most 77 significant byte first (like Motorola and SPARC, unlike Intel). 78 Some versions of gcc may have BYTE_ORDER or __BYTE_ORDER defined 79 If your big endian system isn't being detected, add an OS specific check 80 */ 81 #if (defined(BYTE_ORDER) && BYTE_ORDER==BIG_ENDIAN) || \ 82 (defined(__BYTE_ORDER) && __BYTE_ORDER==__BIG_ENDIAN) || \ 83 defined(__BIG_ENDIAN__) 84 /* Set the native cpu bit order (FILLORDER_LSB2MSB or FILLORDER_MSB2LSB) */ 85 #define HOST_FILLORDER FILLORDER_MSB2LSB 86 /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian (Intel) */ 87 #define WORDS_BIGENDIAN 1 88 /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian (Intel) */ 89 #define HOST_BIGENDIAN 1 90 #else 91 /* Set the native cpu bit order (FILLORDER_LSB2MSB or FILLORDER_MSB2LSB) */ 92 #define HOST_FILLORDER FILLORDER_LSB2MSB 93 /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian (Intel) */ 94 #undef WORDS_BIGENDIAN 95 /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian (Intel) */ 96 #undef HOST_BIGENDIAN 97 #endif // BYTE_ORDER 98 99 /* Support CCITT Group 3 & 4 algorithms */ 100 #define CCITT_SUPPORT 1 101 102 /* Support JPEG compression (requires IJG JPEG library) */ 103 #define JPEG_SUPPORT 1 104 105 /* Support JBIG compression (requires JBIG-KIT library) */ 106 /* #undef JBIG_SUPPORT */ 107 108 /* Support LogLuv high dynamic range encoding */ 109 #define LOGLUV_SUPPORT 1 110 111 /* Support LZW algorithm */ 112 #define LZW_SUPPORT 1 113 114 /* Support NeXT 2-bit RLE algorithm */ 115 #define NEXT_SUPPORT 1 116 117 /* Support Old JPEG compresson (read contrib/ojpeg/README first! Compilation 118 fails with unpatched IJG JPEG library) */ 119 #define OJPEG_SUPPORT 1 120 121 /* Support Macintosh PackBits algorithm */ 122 #define PACKBITS_SUPPORT 1 123 124 /* Support Pixar log-format algorithm (requires Zlib) */ 125 #define PIXARLOG_SUPPORT 1 126 127 /* Support ThunderScan 4-bit RLE algorithm */ 128 #define THUNDER_SUPPORT 1 129 130 /* Support Deflate compression */ 131 #define ZIP_SUPPORT 1 132 133 /* Support LZMA2 compression */ 134 #undef LZMA_SUPPORT 135 136 /* Support Microsoft Document Imaging format */ 137 #undef MDI_SUPPORT 138 139 /* Support strip chopping (whether or not to convert single-strip uncompressed 140 images to mutiple strips of ~8Kb to reduce memory usage) */ 141 #define STRIPCHOP_DEFAULT TIFF_STRIPCHOP 142 143 /* Enable SubIFD tag (330) support */ 144 #define SUBIFD_SUPPORT 1 145 146 /* Treat extra sample as alpha (default enabled). The RGBA interface will 147 treat a fourth sample with no EXTRASAMPLE_ value as being ASSOCALPHA. Many 148 packages produce RGBA files but don't mark the alpha properly. */ 149 #define DEFAULT_EXTRASAMPLE_AS_ALPHA 1 150 151 /* Pick up YCbCr subsampling info from the JPEG data stream to support files 152 lacking the tag (default enabled). */ 153 #define CHECK_JPEG_YCBCR_SUBSAMPLING 1 154 155 /* Support MS MDI magic number files as TIFF */ 156 /* #undef MDI_SUPPORT */ 157 158 /* 159 * Feature support definitions. 160 * XXX: These macros are obsoleted. Don't use them in your apps! 161 * Macros stays here for backward compatibility and should be always defined. 162 */ 163 #define COLORIMETRY_SUPPORT 164 #define YCBCR_SUPPORT 165 #define CMYK_SUPPORT 166 #define ICC_SUPPORT 167 #define PHOTOSHOP_SUPPORT 168 #define IPTC_SUPPORT 169 170 #endif /* _TIFFCONF_ */ 171