Commit Graph

14 Commits

Author SHA1 Message Date
Vadim Zeitlin
193c1c7394 Create tag for v4.2.0
-----BEGIN PGP SIGNATURE-----
 
 iHUEABEIAB0WIQTr39shsCDuj9FRqI3jAQR94RmJdQUCX95KfAAKCRDjAQR94RmJ
 ddHsAP9aNuHBYnueUqBjE34GjNwgwh8rt01MrUT6qYLBomlClgD+L3Xed/AbZH6k
 k3RLq2Wyd7YPMyi6/I9FbIw5av98Dis=
 =RqwF
 -----END PGP SIGNATURE-----

Merge tag 'v4.2.0' into wx

Update to the latest upstream release and rerun autogen.sh.
2020-12-30 17:56:13 +01:00
Even Rouault
4c4965a9df
.gitignore: add entries for new files in test/ 2020-10-12 20:20:38 +02:00
Maarten Bent
a55183aada Create tag for v4.1.0
-----BEGIN PGP SIGNATURE-----
 
 iHQEABEIAB0WIQTr39shsCDuj9FRqI3jAQR94RmJdQUCXb81vgAKCRDjAQR94RmJ
 dbHRAPjy7sZSwOMOGJXpE+/1q0OCWB7iWWQqy7TPb9+8HdtlAQCJXl0nJ423/DJ4
 JKmIRQXuXZ4SP33SCuh34O0VR/HX1g==
 =3q0Z
 -----END PGP SIGNATURE-----

Merge tag 'v4.1.0' into wx

Create tag for v4.1.0

# gpg verification failed.
2020-01-16 21:43:13 +01:00
Bob Friesenhahn
73975cbcb2 Ignore emacs temporary files (ending with tilde character). 2019-11-03 13:47:08 -06:00
Thomas Bernard
69ce2652ef
Add test to check that libtiff types have the correct size
in configure/CMakeList.txt :

- TIFF_INT8_T/TIFF_UINT8_T is signed/unsigned char
sizeof(char)==1 in C standard
- TIFF_INT16_T/TIFF_UINT16_T is signed/unsigned short
sizeof(short)>=2 in C standard
- TIFF_INT32_T/TIFF_UINT32_T is defined so its sizeof() is 4

- TIFF_INT64_T/TIFF_UINT64_T is defined so its sizeof() is 8

- TIFF_SIZE_T is defined so it has same sizeof() than size_t

- TIFF_SSIZE_T is defined so it has same sizeof() than unsigned char *
2019-05-31 20:10:51 +02:00
Even Rouault
eaeca6274a
Add TIFFDeferStrileArrayWriting() and TIFFForceStrileArrayWriting()
Those advanced writing functions must be used in a particular sequence
to make their intended effect. Their aim is to control when/where
the [Strip/Tile][Offsets/ByteCounts] arrays are written into the file.

The purpose of this is to generate 'cloud-optimized geotiff' files where
the first KB of the file only contain the IFD entries without the potentially
large strile arrays. Those are written afterwards.

The typical sequence of calls is:
TIFFOpen()
[ TIFFCreateDirectory(tif) ]
Set fields with calls to TIFFSetField(tif, ...)
TIFFDeferStrileArrayWriting(tif)
TIFFWriteCheck(tif, ...)
 TIFFWriteDirectory(tif)
 ... potentially create other directories and come back to the above directory
TIFFForceStrileArrayWriting(tif): emit the arrays at the end of file

See test/defer_strile_writing.c for a practical example.
2019-05-25 11:37:34 +02:00
Even Rouault
371ad2658c
Make defer strile offset/bytecount loading available at runtime
... and add per-strile offset/bytecount loading capabilities.

Part of this commit makes the behaviour that was previously met when
libtiff was compiled with -DDEFER_STRILE_LOAD available for default builds
when specifying the new 'D' (Deferred) TIFFOpen() flag. In that mode, the [Tile/Strip][ByteCounts/Offsets]
arrays are only loaded when first accessed. This can speed-up the opening
of files stored on the network when just metadata retrieval is needed.
This mode has been used for years by the GDAL library when compiled with
its embeded libtiff copy.

To avoid potential out-of-tree code (typically codecs) that would use
the td_stripbytecount and td_stripoffset array inconditionnaly assuming they
have been loaded, those have been suffixed with _p (for protected). The
use of the new functions mentionned below is then recommended.

Another addition of this commit is the capability of loading only the
values of the offset/bytecount of the strile of interest instead of the
whole array. This is enabled with the new 'O' (Ondemand) flag of TIFFOpen()
(which implies 'D'). That behaviour has also been used by GDAL, which hacked
into the td_stripoffset/td_stripbytecount arrays directly. The new code
added in the _TIFFFetchStrileValue() and _TIFFPartialReadStripArray() internal
functions is mostly a port of what was in GDAL GTiff driver previously.

Related to that, the public TIFFGetStrileOffset[WithErr]() and TIFFGetStrileByteCount[WithErr]()
functions have been added to API. They are of particular interest when
using sparse files (with offset == bytecount == 0) and you want to detect
if a strile is present or not without decompressing the data, or updating
an existing sparse file.
They will also be used to enable a future enhancement where client code can entirely
skip bytecount loading in some situtations

A new test/defer_strile_loading.c test has been added to test the above
capabilities.
2019-05-10 14:46:45 +02:00
Thomas Bernard
578f3f4600
add test/ files to .gitignore 2019-01-29 16:37:09 +01:00
Maarten Bent
0725740623 Create tag for v4.0.10
-----BEGIN PGP SIGNATURE-----
 
 iHUEABEIAB0WIQTr39shsCDuj9FRqI3jAQR94RmJdQUCW+b+SgAKCRDjAQR94RmJ
 dVERAQCGCSozFaK8M9k0MEgvsWcg1lMr/5VfAmUCfiLIDL7OygEAz0ZoTuYxpAxt
 gz2+JmWNlJIlseQZemczpJh5lToiXuM=
 =bMQi
 -----END PGP SIGNATURE-----

Merge tag 'v4.0.10' into wx
2018-11-17 13:24:09 +01:00
Bob Friesenhahn
64ee065f13 Ignore generated files 2018-11-03 09:34:52 -05:00
Vadim Zeitlin
aa65abe076 Merge remote-tracking branch 'upstream/master' into wx
Regenerate the files produced by autotools removed upstream as our build
system relies on having them.
2018-01-28 17:20:14 +01:00
Even Rouault
64541f2893 .gitignore: add patterns for build from root 2017-12-01 16:00:49 +01:00
Even Rouault
2440a113ea Remove autoconf/automake generated files, and add them to .gitignore 2017-12-01 15:54:48 +01:00
Even Rouault
b48399eabe Add .gitignore 2017-11-30 18:23:40 +01:00