tiffconf.h 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  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. #ifndef _TIFFCONF_
  7. #define _TIFFCONF_
  8. #ifdef _WIN32 // Windows
  9. #define PLATFORM(windows, unix) windows
  10. #else
  11. #define PLATFORM(windows, unix) unix
  12. #endif
  13. #if defined _WIN64 || defined __LP64__ // 64-bit platform
  14. #define X64 1
  15. #else
  16. #define X64 0
  17. #endif
  18. #ifndef _WIN32
  19. #include <stdint.h>
  20. #endif
  21. typedef PLATFORM( signed __int8 , int8_t) I8 , SByte; // Signed Int ( 8-bit) -128 .. 127
  22. typedef PLATFORM(unsigned __int8 , uint8_t) U8 , Byte; // Unsigned Int ( 8-bit) 0 .. 255
  23. typedef PLATFORM( signed __int16, int16_t) I16, Short; // Signed Int (16-bit) -32 768 .. 32 767
  24. typedef PLATFORM(unsigned __int16, uint16_t) U16, UShort; // Unsigned Int (16-bit) 0 .. 65 535
  25. typedef PLATFORM( signed __int32, int32_t) I32, Int; // Signed Int (32-bit) -2 147 483 648 .. 2 147 483 647
  26. typedef PLATFORM(unsigned __int32, uint32_t) U32, UInt; // Unsigned Int (32-bit) 0 .. 4 294 967 295
  27. typedef PLATFORM( signed __int64, int64_t) I64, Long; // Signed Int (64-bit) -9 223 372 036 854 775 808 .. 9 223 372 036 854 775 807
  28. typedef PLATFORM(unsigned __int64, uint64_t) U64, ULong; // Unsigned Int (64-bit) 0 .. 18 446 744 073 709 551 615
  29. #if X64
  30. typedef I64 IntPtr; // Signed Int capable of storing full memory address (needs to be 64-bit on 64-bit platforms)
  31. typedef U64 UIntPtr; // Unsigned Int capable of storing full memory address (needs to be 64-bit on 64-bit platforms)
  32. #else
  33. typedef I32 IntPtr; // Signed Int capable of storing full memory address (needs to be 32-bit on 32-bit platforms)
  34. typedef U32 UIntPtr; // Unsigned Int capable of storing full memory address (needs to be 32-bit on 32-bit platforms)
  35. #endif
  36. /* Define to 1 if the system has the type `int16'. */
  37. /* #undef HAVE_INT16 */
  38. /* Define to 1 if the system has the type `int32'. */
  39. /* #undef HAVE_INT32 */
  40. /* Define to 1 if the system has the type `int8'. */
  41. /* #undef HAVE_INT8 */
  42. /* The size of a `int', as computed by sizeof. */
  43. #define SIZEOF_INT sizeof(int)
  44. /* Signed 8-bit type */
  45. #define TIFF_INT8_T I8
  46. /* Unsigned 8-bit type */
  47. #define TIFF_UINT8_T U8
  48. /* Signed 16-bit type */
  49. #define TIFF_INT16_T I16
  50. /* Unsigned 16-bit type */
  51. #define TIFF_UINT16_T U16
  52. /* Signed 32-bit type formatter */
  53. #define TIFF_INT32_FORMAT "%d"
  54. /* Signed 32-bit type */
  55. #define TIFF_INT32_T I32
  56. /* Unsigned 32-bit type formatter */
  57. #define TIFF_UINT32_FORMAT "%u"
  58. /* Unsigned 32-bit type */
  59. #define TIFF_UINT32_T U32
  60. /* Signed 64-bit type formatter */
  61. #define TIFF_INT64_FORMAT "%I64d"
  62. /* Signed 64-bit type */
  63. #define TIFF_INT64_T I64
  64. /* Unsigned 64-bit type formatter */
  65. #define TIFF_UINT64_FORMAT "%I64u"
  66. /* Unsigned 64-bit type */
  67. #define TIFF_UINT64_T U64
  68. /* Signed size type */
  69. # define TIFF_SSIZE_T IntPtr
  70. /* Compatibility stuff. */
  71. /* Define as 0 or 1 according to the floating point format suported by the
  72. machine */
  73. #define HAVE_IEEEFP 1
  74. /* Set the native cpu bit order (FILLORDER_LSB2MSB or FILLORDER_MSB2LSB) */
  75. #define HOST_FILLORDER FILLORDER_LSB2MSB
  76. /* Native cpu byte order: 1 if big-endian (Motorola) or 0 if little-endian
  77. (Intel) */
  78. #define HOST_BIGENDIAN 0
  79. /* Support CCITT Group 3 & 4 algorithms */
  80. #define CCITT_SUPPORT 1
  81. /* Support JPEG compression (requires IJG JPEG library) */
  82. /* #undef JPEG_SUPPORT */
  83. /* Support JBIG compression (requires JBIG-KIT library) */
  84. /* #undef JBIG_SUPPORT */
  85. /* Support LogLuv high dynamic range encoding */
  86. #define LOGLUV_SUPPORT 1
  87. /* Support LZW algorithm */
  88. #define LZW_SUPPORT 1
  89. /* Support NeXT 2-bit RLE algorithm */
  90. #define NEXT_SUPPORT 1
  91. /* Support Old JPEG compresson (read contrib/ojpeg/README first! Compilation
  92. fails with unpatched IJG JPEG library) */
  93. /* #undef OJPEG_SUPPORT */
  94. /* Support Macintosh PackBits algorithm */
  95. #define PACKBITS_SUPPORT 1
  96. /* Support Pixar log-format algorithm (requires Zlib) */
  97. /* #undef PIXARLOG_SUPPORT */
  98. /* Support ThunderScan 4-bit RLE algorithm */
  99. #define THUNDER_SUPPORT 1
  100. /* Support Deflate compression */
  101. #define ZIP_SUPPORT 1
  102. /* Support strip chopping (whether or not to convert single-strip uncompressed
  103. images to mutiple strips of ~8Kb to reduce memory usage) */
  104. #define STRIPCHOP_DEFAULT TIFF_STRIPCHOP
  105. /* Enable SubIFD tag (330) support */
  106. #define SUBIFD_SUPPORT 1
  107. /* Treat extra sample as alpha (default enabled). The RGBA interface will
  108. treat a fourth sample with no EXTRASAMPLE_ value as being ASSOCALPHA. Many
  109. packages produce RGBA files but don't mark the alpha properly. */
  110. #define DEFAULT_EXTRASAMPLE_AS_ALPHA 1
  111. /* Pick up YCbCr subsampling info from the JPEG data stream to support files
  112. lacking the tag (default enabled). */
  113. #define CHECK_JPEG_YCBCR_SUBSAMPLING 1
  114. /* Support MS MDI magic number files as TIFF */
  115. /* #undef MDI_SUPPORT */
  116. /*
  117. * Feature support definitions.
  118. * XXX: These macros are obsoleted. Don't use them in your apps!
  119. * Macros stays here for backward compatibility and should be always defined.
  120. */
  121. #define COLORIMETRY_SUPPORT
  122. #define YCBCR_SUPPORT
  123. #define CMYK_SUPPORT
  124. #define ICC_SUPPORT
  125. #define PHOTOSHOP_SUPPORT
  126. #define IPTC_SUPPORT
  127. #endif /* _TIFFCONF_ */
  128. /*
  129. * Local Variables:
  130. * mode: c
  131. * c-basic-offset: 8
  132. * fill-column: 78
  133. * End:
  134. */