Skip to main content

Module tiff

Module tiff 

Source
Expand description

Zero-copy TIFF / TIFF-EP / DNG IFD parsing.

Most RAW formats are TIFF-based (DNG, CR2, NEF, ARW, PEF, ORF, RW2, SRW, 3FR, IIQ maker data, …). Tiff::parse reads the IFD chain plus SubIFDs and the EXIF/GPS IFDs into an in-memory tree of Ifds whose entries reference the source bytes. Values are decoded lazily by the typed accessors on Entry.

Robustness: IFD offsets are tracked in a visited set (cyclic chains are cut), recursion depth and total IFD count are bounded, and every value access is bounds checked.

Modules§

tags
Well-known tag numbers.
types
TIFF field types.

Structs§

Entry
A single IFD entry. data holds the raw value bytes (inline or referenced).
Ifd
An Image File Directory.
Tiff
A parsed TIFF structure.
TiffOptions
Parsing options.

Functions§

parse_ifd_at
Parse a single IFD (and its children) at offset of data.
type_size
Byte size of one value of TIFF type t (0 for unknown types).