Skip to content

Commit

Permalink
upgrade vendored libtiff to 4.6.0
Browse files Browse the repository at this point in the history
Closes: #397
  • Loading branch information
sezero committed Oct 29, 2023
1 parent 3e86295 commit 4953d01
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
[submodule "external/libtiff"]
path = external/libtiff
url = https://github.com/libsdl-org/libtiff.git
branch = v4.5.1-SDL
branch = v4.6.0-SDL
[submodule "external/zlib"]
path = external/zlib
url = https://github.com/libsdl-org/zlib.git
Expand Down
3 changes: 2 additions & 1 deletion VisualC/external/include/tiff.h
Original file line number Diff line number Diff line change
Expand Up @@ -646,7 +646,7 @@ typedef enum
#define TIFFTAG_EP_EXPOSUREINDEX 37397 /* Exposure index */
#define TIFFTAG_EP_STANDARDID 37398 /* TIFF/EP standard version, n.n.n.n */
#define TIFFTAG_EP_SENSINGMETHOD 37399 /* Type of image sensor */
/*
/*
* TIFF/EP tags equivalent to EXIF tags
* Note that TIFF-EP and EXIF use nearly the same metadata tag set, but TIFF-EP stores the tags in IFD 0,
* while EXIF store the tags in a separate IFD. Either location is allowed by DNG, but the EXIF location is preferred.
Expand Down Expand Up @@ -761,6 +761,7 @@ typedef enum
#define TIFFTAG_LERC_MAXZERROR 65567 /* LERC maximum error */
#define TIFFTAG_WEBP_LEVEL 65568 /* WebP compression level */
#define TIFFTAG_WEBP_LOSSLESS 65569 /* WebP lossless/lossy */
#define TIFFTAG_WEBP_LOSSLESS_EXACT 65571 /* WebP lossless exact mode. Set-only mode. Default is 1. Can be set to 0 to increase compression rate, but R,G,B in areas where alpha = 0 will not be preserved */
#define TIFFTAG_DEFLATE_SUBCODEC 65570 /* ZIP codec: to get/set the sub-codec to use. Will default to libdeflate when available */
#define DEFLATE_SUBCODEC_ZLIB 0
#define DEFLATE_SUBCODEC_LIBDEFLATE 1
Expand Down
2 changes: 1 addition & 1 deletion VisualC/external/include/tiffio.h
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ typedef struct
#define LOGLUV_PUBLIC 1
#endif

#if defined(__GNUC__) || defined(__attribute__)
#if defined(__GNUC__) || defined(__clang__) || defined(__attribute__)
#define TIFF_ATTRIBUTE(x) __attribute__(x)
#else
#define TIFF_ATTRIBUTE(x) /*nothing*/
Expand Down
14 changes: 10 additions & 4 deletions VisualC/external/include/tiffvers.h
Original file line number Diff line number Diff line change
@@ -1,22 +1,28 @@
/* tiffvers.h version information is updated according to version information
* in configure.ac */

/* clang-format off */

/* clang-format disabled because FindTIFF.cmake is very sensitive to the
* formatting of below line being a single line.
* Furthermore, configure_file variables of type "@VAR@" are
* modified by clang-format and won't be substituted by CMake.
*/
#define TIFFLIB_VERSION_STR "LIBTIFF, Version 4.5.1\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc."
#define TIFFLIB_VERSION_STR "LIBTIFF, Version 4.6.0\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc."
/*
* This define can be used in code that requires
* compilation-related definitions specific to a
* version or versions of the library. Runtime
* version checking should be done based on the
* string returned by TIFFGetVersion.
*/
#define TIFFLIB_VERSION 20230609
#define TIFFLIB_VERSION 20230908

/* The following defines have been added in 4.5.0 */
#define TIFFLIB_MAJOR_VERSION 4
#define TIFFLIB_MINOR_VERSION 5
#define TIFFLIB_MICRO_VERSION 1
#define TIFFLIB_MINOR_VERSION 6
#define TIFFLIB_MICRO_VERSION 0
#define TIFFLIB_VERSION_STR_MAJ_MIN_MIC "4.6.0"

/* Macro added in 4.5.0. Returns TRUE if the current libtiff version is
* greater or equal to major.minor.micro
Expand Down
Binary file modified VisualC/external/optional/x64/libtiff-6.dll
Binary file not shown.
Binary file modified VisualC/external/optional/x86/libtiff-6.dll
Binary file not shown.
2 changes: 1 addition & 1 deletion external/libtiff
Submodule libtiff updated 215 files

0 comments on commit 4953d01

Please sign in to comment.