1TIFFSetDirectory(3TIFF) TIFFSetDirectory(3TIFF)
2
3
4
6 TIFFSetDirectory, TIFFSetSubDirectory - set the current directory for
7 an open TIFF file
8
10 #include <tiffio.h>
11
12 int TIFFSetDirectory(TIFF *tif, tdir_t dirnum)
13 int TIFFSetSubDirectory(TIFF *tif, uint64_t diroff)
14
16 TIFFSetDirectory changes the current directory and reads its contents
17 with TIFFReadDirectory. The parameter dirnum specifies the subfile/di‐
18 rectory as an integer number, with the first directory numbered zero.
19
20 TIFFSetSubDirectory acts like TIFFSetDirectory, except the directory is
21 specified as a file offset instead of an index; this is required for
22 accessing subdirectories linked through a SubIFD tag.
23
25 On successful return 1 is returned. Otherwise, 0 is returned if dirnum
26 or diroff specifies a non-existent directory, or if an error was en‐
27 countered while reading the directory's contents.
28
30 All error messages are directed to the TIFFError(3TIFF) routine.
31
32 %s: Error fetching directory count. An error was encountered while
33 reading the ``directory count'' field.
34
35 %s: Error fetching directory link. An error was encountered while
36 reading the ``link value'' that points to the next directory in a file.
37
39 TIFFCurrentDirectory(3TIFF), TIFFOpen(3TIFF), TIFFReadDirectory(3TIFF),
40 TIFFWriteDirectory(3TIFF), libtiff(3TIFF)
41
42 Libtiff library home page: http://www.simplesystems.org/libtiff/
43
44
45
46libtiff October 15, 1995 TIFFSetDirectory(3TIFF)