Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
TIFF
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Details == TIFF is a flexible, adaptable file format for handling images and data within a single file, by including the header tags (size, definition, image-data arrangement, applied [[image compression]]) defining the image's geometry. A TIFF file, for example, can be a container holding [[JPEG]] (lossy) and [[PackBits]] (lossless) compressed images. A TIFF file also can include a [[Vector graphics|vector]]-based [[clipping path]] (outlines, croppings, image frames). The ability to store image data in a [[Lossless data compression|lossless]] format makes a TIFF file a useful image archive, because, unlike standard JPEG files, a TIFF file using lossless compression (or none) may be edited and re-saved without losing image quality. This is not the case when using the TIFF as a container holding compressed JPEG. Other TIFF options are [[Layers (digital image editing)|layers]] and pages. TIFF offers the option of using [[Lempel-Ziv-Welch|LZW]] compression, a lossless data-compression technique for reducing a file's size. Use of this option was limited by patents on the LZW technique until their expiration in 2004. The TIFF 6.0 specification consists of the following parts:<ref name="tiff6" /> * Introduction (contains information about TIFF Administration, usage of Private fields and values, etc.) * Part 1: Baseline TIFF * Part 2: TIFF Extensions * Part 3: Appendices === {{anchor|Baseline TIFF}}Part 1: Baseline TIFF === When TIFF was introduced, its extensibility provoked compatibility problems. The flexibility in encoding gave rise to the joke that TIFF stands for ''Thousands of Incompatible File Formats''.<ref name="trauth"/> To avoid these problems, every TIFF reader was required to read ''Baseline TIFF''. Among other things, Baseline TIFF does not include layers, or compressed JPEG or LZW images. Baseline TIFF is formally known as ''TIFF 6.0, Part 1: Baseline TIFF''. The following is an incomplete list of required Baseline TIFF features:<ref name="tiff6" /> ==== Multiple subfiles ==== TIFF readers must be prepared for multiple/multi-page images (subfiles) per TIFF file, although they are not required to actually do anything with images after the first one. There may be more than one Image File Directory (IFD) in a TIFF file. Each IFD defines a subfile. One use of subfiles is to describe related images, such as the pages of a facsimile document. A Baseline TIFF reader is not required to read any IFD beyond the first one.<ref name="tiff6" /> ==== Strips ==== A baseline TIFF image is composed of one or more strips. A strip (or band) is a subsection of the image composed of one or more rows. Each strip may be compressed independently of the entire image, and each begins on a byte boundary. If the image height is not evenly divisible by the number of rows in the strip, the last strip may contain fewer rows. If strip definition tags are omitted, the image is assumed to contain a single strip. ==== Compression ==== Baseline TIFF readers must handle the following three compression schemes:<ref name="tiff6" /> * Zero compression * [[ITU-T|CCITT]] Group 3 1-Dimensional Modified [[Huffman coding|Huffman]] RLE * [[PackBits]] compression - a form of [[run-length encoding]] ==== Image types ==== Baseline TIFF image types are: bilevel, grayscale, palette-color, and RGB full-color images.<ref name="tiff6" /> ==== Byte order ==== Every TIFF file begins with a two-[[byte]] indicator of [[byte order]]: "<code>II</code>" for little-endian (a.k.a. "Intel byte ordering", {{circa|1980}})<ref name="ReferenceA">David Beecher, author of dozens of image processing engines over the last 30 years. Any TIFF file can be viewed with a HEX editor to confirm this.</ref> or "<code>MM</code>" for big-endian (a.k.a. "Motorola byte ordering", {{circa|1980}})<ref name="ReferenceA"/> byte ordering. The next two-byte word contains the format version number, which has always been 42 for every version of TIFF (e.g., TIFF v5.0 and TIFF v6.0).<ref>{{cite book | author = Aldus/Microsoft | title = TIFF | section = 1) Structure | version = Revision 5.0 | publisher = Aldus Corporation and Microsoft Corporation | date = 1988-08-08 | url = http://cool-palimpsest.stanford.edu/bytopic/imaging/std/tiff5.html | archive-url = https://web.archive.org/web/20081204070129/http://cool-palimpsest.stanford.edu/bytopic/imaging/std/tiff5.html |archive-date = 2008-12-04 | access-date = 2009-06-29 | quote = The number 42 was chosen for its deep philosophical significance. }}</ref> All two-byte words, double words, etc., in the TIFF file are assumed to be in the indicated byte order. The TIFF 6.0 specification states that compliant TIFF readers must support both byte orders (<code>II</code> and <code>MM</code>); writers may use either.<ref>{{cite book |author = Adobe Developers Association |title = TIFF |section = Section 7: Additional baseline TIFF Requirements |version = Revision 6.0 |publisher = Adobe Systems Incorporated |date = 1992-06-03 |url = https://www.adobe.io/content/dam/udp/en/open/standards/tiff/TIFF6.pdf |access-date = 2022-06-29 |quote = ‘MM’ and ‘II’ byte order. TIFF readers must be able to handle both byte orders. TIFF writers can do whichever is most convenient or efficient. |page = 26 |archive-url=https://web.archive.org/web/20210108174645/https://www.adobe.io/content/dam/udp/en/open/standards/tiff/TIFF6.pdf |archive-date=8 January 2021 |url-status=dead}}</ref> ==== Other TIFF fields ==== TIFF readers must be prepared to encounter and ignore private fields not described in the TIFF specification. TIFF readers must not refuse to read a TIFF file if optional fields do not exist.<ref name="tiff6" /> === {{anchor|TIFF Extensions}}Part 2: TIFF Extensions === Many TIFF readers support tags additional to those in Baseline TIFF, but not every reader supports every extension.<ref>{{cite web |url=http://support.microsoft.com/kb/319196/en-us |title=You cannot preview scanned TIFF file in Windows Picture and Fax Viewer |author=Microsoft |access-date=2011-02-28}}</ref><ref name="wfax-packbits">{{cite web |url=http://support.microsoft.com/kb/329270 |title=You Cannot View TIFF Images Using Windows Picture and Fax Viewer |author=Microsoft |access-date=2011-02-28}}</ref><ref>{{cite web |url=http://suppressingfire.org/~burner/evil-mods-tiff/ |title=Handling Microsoft Office Document Scanning TNEF and TIFFs in Linux |author=Microsoft |access-date=2011-02-28 |url-status=dead |archive-url=https://web.archive.org/web/20130430204808/http://suppressingfire.org/~burner/evil-mods-tiff/ |archive-date=2013-04-30 }}</ref> As a consequence, Baseline TIFF features became the lowest common denominator for TIFF. Baseline TIFF features are extended in TIFF Extensions (defined in the TIFF 6.0 Part 2 specification) but extensions can also be defined in private tags. The TIFF Extensions are formally known as ''TIFF 6.0, Part 2: TIFF Extensions''. Here are some examples of TIFF extensions defined in TIFF 6.0 specification:<ref name="tiff6" /> ====Compression==== * CCITT T.4 bi-level encoding * CCITT T.6 bi-level encoding * [[Lempel–Ziv–Welch|LZW]] * [[JPEG]] ====Image types==== * [[CMYK]] Images * [[YCbCr]] Images * HalftoneHints * Tiled Images * [[CIE Lab|CIE L*a*b*]] Images ====Image trees==== A baseline TIFF file can contain a sequence of images (IFD). Typically, all the images are related but represent different data, such as the pages of a document. In order to explicitly support multiple views of the ''same'' data, the ''SubIFD'' tag was introduced.<ref name="supplement1">[https://web.archive.org/web/20060114005938/http://partners.adobe.com/public/developer/en/tiff/TIFFPM6.pdf TIFF Specification Supplement 1], Retrieved 2022-06-29</ref> This allows the images to be defined along a [[tree structure]]. Each image can have a sequence of children, each child being itself an image. The typical usage is to provide thumbnails or several versions of an image in different color spaces. =====Tiles===== A TIFF image may also be composed of a number of tiles. All tiles in the same image have the same dimensions and may be compressed independently of the entire image, similar to strips (see above). Tiled images are part of TIFF 6.0, Part 2: TIFF Extensions, so the support for tiled images is not required in Baseline TIFF readers. ====Other extensions==== According to TIFF 6.0 specification (Introduction), all TIFF files using proposed TIFF extensions that are not approved by Adobe as part of Baseline TIFF (typically for specialized uses of TIFF that do not fall within the domain of publishing or general graphics or picture interchange) should be either not called TIFF files or should be marked some way so that they will not be confused with mainstream TIFF files. ==== Private tags ==== Developers can apply for a block of "private tags" to enable them to include their own proprietary information inside a TIFF file without causing problems for file interchange. TIFF readers are required to ignore tags that they do not recognize, and a registered developer's private tags are guaranteed not to clash with anyone else's tags or with the standard set of tags defined in the specification. Private tags are numbered in the range 32,768 and higher. Private tags are reserved for information meaningful only for some organization, or for experiments with a new compression scheme within TIFF. Upon request, the TIFF administrator (currently Adobe) will allocate and register one or more private tags for an organization, to avoid possible conflicts with other organizations. Organizations and developers are discouraged from choosing their own tag numbers arbitrarily, because doing so could cause serious compatibility problems. However, if there is little or no chance that TIFF files will escape a private environment, organizations and developers are encouraged to consider using TIFF tags in the "reusable" 65,000–65,535 range. There is no need to contact Adobe when using numbers in this range.<ref name="tiff6" /> ===TIFF Compression Tag=== The TIFF Tag 259 (0103<sub>16</sub>) stores the information about the Compression method. The default value is 1 = no compression. Most TIFF writers and TIFF readers support only some TIFF compression schemes. Here are some examples of used TIFF compression schemes: {|class="wikitable sortable" style="width: 100%" |+ TIFF Compression Tag<ref name="wfax-packbits" /><ref>{{cite web |url=http://www.awaresystems.be/imaging/tiff/tifftags/compression.html |title=Baseline TIFF Tag Compression |access-date=2011-02-26}}</ref><ref>{{cite web |url=http://www.libtiff.org/support.html |title=LibTIFF - TIFF 6.0 Specification Coverage |access-date=2011-02-28}}</ref><ref>{{cite web|url=http://hul.harvard.edu/jhove/tiff-tags.html |title=JSTOR/Harvard Object Validation Environment - TIFF Compression Schemes |access-date=2011-02-26 |url-status=dead |archive-url=https://web.archive.org/web/20110130161333/http://hul.harvard.edu/jhove/tiff-tags.html |archive-date=January 30, 2011 }}</ref><ref>{{cite web|url=http://hul.harvard.edu/jhove/tiff-hul.html |title=JSTOR/Harvard Object Validation Environment - JHOVE TIFF-hul Module |access-date=2011-02-26 |url-status=dead |archive-url=https://web.archive.org/web/20101210133003/http://hul.harvard.edu/jhove/tiff-hul.html |archive-date=December 10, 2010 }}</ref><ref>{{cite web |url=http://tiki-lounge.com/~raf/tiff/tifffields.html |title=TIFF Fields |access-date=2011-02-27}}</ref><ref>{{cite web |url=http://www.digitalpreservation.gov/formats/content/tiff_tags.shtml |title=Tags for TIFF and Related Specifications |author=Library of Congress Collections |access-date=2011-02-27}}</ref><ref>{{cite web |url=http://docs.gimp.org/en/gimp-images-out.html#file-tiff-save |title=GIMP Documentation - Saving as TIFF |access-date=2011-02-27}}</ref><ref>{{cite web |url=http://www.irfanview.com/history_old.htm |title=IrfanView - History of changes |access-date=2011-02-27}}</ref> |- ! Tag value ! Compression scheme ! Lossy/<wbr>lossless ! Specification ! Description ! Image types ! Usage and support |- | 0001<sub>16</sub> || None || Lossless || TIFF 6.0 || Baseline TIFF || All || {{yes|Common}}<ref>Commonly supported TIFF types can be displayed by image viewers such as [[Irfanview]]</ref> |- | 0002<sub>16</sub> || CCITT Group 3 1-Dimensional Modified Huffman run-length encoding (a.k.a. MH or CCITT 1D) || Lossless || TIFF 6.0 || Baseline TIFF; compression based on ITU-T T.4 || Black and white || {{yes|Common}} |- | 0003<sub>16</sub> || CCITT T.4 bi-level encoding as specified in section 4, Coding, of [//www.itu.int/rec/T-REC-T.4/en ITU-T Recommendation T.4] (a.k.a. CCITT Group 3 fax encoding or CCITT Group 3 2D) || Lossless || TIFF 6.0 || TIFF 6.0 Extensions; compression based on ITU-T T.4 || Black and white || {{yes|Common}} |- | 0004<sub>16</sub> || CCITT T.6 bi-level encoding as specified in section 2 of [//www.itu.int/rec/T-REC-T.6/en ITU-T Recommendation T.6] (a.k.a. [[Group 4 compression|CCITT Group 4 fax encoding]]) || Lossless || TIFF 6.0 || TIFF 6.0 extensions; compression based on ITU-T T.6 || Black and white || {{yes|Common}} |- | 0005<sub>16</sub> || [[Lempel–Ziv–Welch]] || Lossless || TIFF 6.0 || TIFF 6.0 Extensions; first defined in TIFF 5 (1988); a patented compression algorithm, but the patents expired in 2003 and 2004 || All || {{yes|Common}}<ref name="succeed">{{cite book|author=Succeed project|year= 2014|title=Recommendations for metadata and data formats for online availability and long-term preservation|url=http://www.succeed-project.eu/sites/default/files/deliverables/Succeed_600555_WP4_D4.1_RecommendationsOnFormatsAndStandards_v1.1.pdf|page=68|quote=If files are actively managed in a digital repository, it is possible to consider using either LZW or ZIP lossless compression for the TIFF files. JPEG compression should not be used within [...] TIFF. [...] Most of the respondents use uncompressed images (64%), if compression is used then LZW is mostly used.}}</ref> |- | 0006<sub>16</sub> || JPEG (obsolete 'old-style' JPEG, later superseded in Technote2) || Lossy || TIFF 6.0 || TIFF 6.0 Extensions; first defined in TIFF 6 (1992); obsolete, should never be written. || Continuous-tone || {{no|Rare}} |- | 0007<sub>16</sub> || JPEG ('new-style' JPEG) || Lossy || TIFF 6 Technote2 (1995) || supersedes old-style JPEG compression; it is a TIFF 6.0 extension. || Continuous-tone || {{partial|Uncommon}} |- | 0008<sub>16</sub> || Deflate (zlib), Adobe variant (official) || Lossless || TIFF Specification Supplement 2 (2002) || RFC 1950 (1996), RFC 1951 (1996), Adobe Photoshop TIFF Technical Notes; it is a TIFF 6.0 extension. || All || {{yes|Common}} |- | 0009<sub>16</sub> || JBIG, per [//www.itu.int/rec/T-REC-T.85/en ITU-T T.85] || Lossless || TIFF-FX || RFC 2301 (1998), RFC 3949 (2005) || Black and white || {{no|Rare}} |- | 000A<sub>16</sub> || JBIG, per [//www.itu.int/rec/T-REC-T.43/en ITU-T T.43] || Lossless || TIFF-FX || RFC 2301 (1998), RFC 3949 (2005) || Black and white || {{no|Rare}} |- | 7FFE<sub>16</sub> || NeXT RLE 2-bit greyscale encoding || || Proprietary || || || {{no|Rare}} |- | 8005<sub>16</sub> || PackBits (a.k.a. Macintosh RLE) || Lossless || TIFF 6.0 || Baseline TIFF || All || {{no|Rare}}<ref name="succeed"/> |- | 8029<sub>16</sub> || ThunderScan RLE 4-bit encoding || || Proprietary || || Black and white || {{no|Rare}} |- | 807F<sub>16</sub> || RasterPadding in continuous tone (CT) or monochrome picture (MP) || Lossless || TIFF/IT (1998, 2004) || ISO 12639 || || {{no|Rare}} |- | 8080<sub>16</sub> || RLE for line work (LW) || Lossless || TIFF/IT (1998, 2004) || ISO 12639 || || {{no|Rare}} |- | 8081<sub>16</sub> || RLE for high-resolution continuous-tone (HC) || Lossless || TIFF/IT (1998, 2004) || ISO 12639 || || {{no|Rare}} |- | 8082<sub>16</sub> || RLE for binary line work (BL) || Lossless || TIFF/IT (1998, 2004) || ISO 12639 || || {{no|Rare}} |- | 80B2<sub>16</sub> || Deflate, PKZIP variant (obsolete) || Lossless || Proprietary || According to TIFF Specification Supplement 2 it should be considered obsolete but reading is recommended || All || {{partial|Uncommon}} |- | 80B3<sub>16</sub> || Kodak DCS || || Proprietary || || || {{no|Rare}} |- | 8765<sub>16</sub> || JBIG || || LibTIFF || || Black and white || {{no|Rare}} |- | 8798<sub>16</sub> || JPEG2000 || || Proprietary || Includes a complete JP2 file inside a TIFF file, not recommended. Introduced by Leadtools.<ref>{{cite web | url=http://www.leadtools.com/sdk/formats/tiff.htm | title=LEADTOOLS TIFF SDK |access-date=2011-07-04 }}</ref> || || {{partial|Uncommon}} |- | 8799<sub>16</sub> || Nikon NEF Compressed || || Proprietary || || || {{no|Rare}} |- | 879B<sub>16</sub> || [[JBIG2]] || Lossless, lossy || TIFF-FX Extension Set 1.0 || Abandoned IETF draft from 2001<ref>{{cite web | url=https://tools.ietf.org/html/draft-ietf-fax-tiff-fx-extension1-01 | title=Draft-ietf-fax-tiff-fx-extension1-01 }}</ref> || || {{no|Rare}} |- | 8847<sub>16</sub> || LERC || Lossy || ESRI LERC || || || {{no|Rare}} |- | 884C<sub>16</sub><ref name="dngSemanticMasks">{{citation|mode=cs1 |url=https://helpx.adobe.com/content/dam/help/en/photoshop/pdf/DNG_Spec_1_7_1_0.pdf#page=17 |page=17–18 |title=Digital Negative (DNG) Specification |date=September 2023 |version=1.7.1.0 |publisher=[[Adobe Inc]] |section=Semantic Masks}}</ref> || Lossy non-YCbCr JPEG || Lossy || [[Digital Negative|DNG]] 1.4.0.0<ref name="dngCompressionFormats">{{citation|mode=cs1 |url=https://helpx.adobe.com/content/dam/help/en/photoshop/pdf/DNG_Spec_1_7_1_0.pdf#page=20 |page=20–22 |title=Digital Negative (DNG) Specification |date=September 2023 |version=1.7.1.0 |publisher=[[Adobe Inc]] |section=Compression}}</ref> || Used for DNG semantic masks<ref name="dngSemanticMasks"/> and for images in the {{code|LinearRaw}} colorspace; explicitly indicates baseline DCT JPEG compression as opposed to "lossless Huffman JPEG".<ref name="dngCompressionFormats"/> || || {{no|Rare}} |- | C350<sub>16</sub> || [[zstd|ZSTD]] || Lossless || LibTIFF || || || {{no|Rare}} |- | C351<sub>16</sub> || [[WebP]] || Lossless, lossy || LibTIFF || || || {{no|Rare}} |- | CD42<sub>16</sub><ref name="dngSemanticMasks"/> || [[JPEG XL]] || Lossless, lossy || DNG 1.7.0.0<ref name="dngCompressionFormats"/> || || || {{no|Rare}} |}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)