home *** CD-ROM | disk | FTP | other *** search
/ The Hacker's Encyclopedia 1998 / hackers_encyclopedia.iso / rfc / 3 / rfc2301.txt < prev    next >
Encoding:
Text File  |  2003-06-11  |  195.8 KB  |  4,315 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7. Network Working Group                                       L. McIntyre
  8. Request for Comments: 2301                            Xerox Corporation
  9. Category: Standards Track                                     S. Zilles
  10.                                                     Adobe Systems, Inc.
  11.                                                              R. Buckley
  12.                                                       Xerox Corporation
  13.                                                              D. Venable
  14.                                                       Xerox Corporation
  15.                                                              G. Parsons
  16.                                                        Northern Telecom
  17.                                                             J. Rafferty
  18.                                                    Human Communications
  19.                                                              March 1998
  20.  
  21.  
  22.  
  23.                       File Format for Internet Fax
  24.  
  25.  
  26. Status of this Memo
  27.  
  28.    This document specifies an Internet standards track protocol for the
  29.    Internet community, and requests discussion and suggestions for
  30.    improvements.  Please refer to the current edition of the "Internet
  31.    Official Protocol Standards" (STD 1) for the standardization state
  32.    and status of this protocol.  Distribution of this memo is unlimited.
  33.  
  34. Copyright Notice
  35.  
  36.    Copyright (C) The Internet Society (1998).  All Rights Reserved.
  37.  
  38. Abstract
  39.  
  40.    This document describes the TIFF (Tag Image File Format)
  41.    representation of image data specified by the ITU-T Recommendations
  42.    for black-and-white and color facsimile. This file format
  43.    specification is commonly known as TIFF-FX. It formally defines
  44.    minimal, extended and lossless JBIG modes (Profiles S, F, J) for
  45.    black-and-white fax, and base JPEG, lossless JBIG and Mixed Raster
  46.    Content modes (Profiles C, L, M) for color and grayscale fax. These
  47.    modes or profiles correspond to the content of the applicable ITU-T
  48.    Recommendations. Files formatted according to this specification use
  49.    the image/tiff MIME Content Type.
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58. McIntyre, et. al.           Standards Track                     [Page 1]
  59.  
  60. RFC 2301              File Format for Internet Fax            March 1998
  61.  
  62.  
  63. Table of Contents
  64.  
  65. 1. INTRODUCTION........................................................4
  66.    1.1. Scope..........................................................5
  67.    1.2. Approach.......................................................5
  68.    1.3. Overview of this draft.........................................5
  69. 2. TIFF and Fax........................................................7
  70.    2.1. TIFF Overview..................................................7
  71.      2.1.1. File Structure.............................................7
  72.      2.1.2. Image Structure............................................9
  73.      2.1.3. TIFF File Structure for Fax Applications..................10
  74.    2.2 TIFF Fields for All Fax Applications...........................11
  75.      2.2.1. TIFF Fields required for all fax modes....................12
  76.      2.2.2. Additional TIFF Fields required for all fax modes.........13
  77.      2.2.3. TIFF Fields recommended for all fax modes.................15
  78.      2.2.4. New TIFF Fields recommended for fax modes.................16
  79. 3. Minimal Black-and-White Fax Mode...................................18
  80.    3.1. Overview......................................................18
  81.    3.2. Required TIFF Fields..........................................18
  82.      3.2.1 Baseline Fields............................................18
  83.      3.2.2 Extension Fields...........................................20
  84.      3.2.3 New Fields.................................................20
  85.    3.3. Recommended TIFF Fields.......................................20
  86.    3.4. End of Line (EOL) and Return to Control (RTC).................20
  87.      3.4.1 RTC Exclusion..............................................21
  88.    3.5. File Structure................................................22
  89.    3.6. Minimal Black-and-White Mode Summary..........................23
  90. 4. Extended Black-and-White Fax Mode..................................24
  91.    4.1. TIFF-F Overview...............................................25
  92.    4.2. Required TIFF Fields..........................................26
  93.      4.2.1. Baseline Fields...........................................26
  94.      4.2.2. Extension Fields..........................................28
  95.      4.2.3. New Fields................................................29
  96.    4.3. Recommended TIFF Fields.......................................29
  97.      4.3.1. Baseline Fields...........................................29
  98.      4.3.2. Extension Fields..........................................29
  99.      4.3.3. New Fields................................................29
  100.    4.4. Technical Implementation Issues...............................30
  101.      4.4.1. Strips....................................................30
  102.      4.4.2. Bit Order.................................................31
  103.      4.4.3. Multi-Page................................................31
  104.      4.4.4. Compression...............................................31
  105.      4.4.5. Example Use of Page-quality Fields........................32
  106.      4.4.6. Practical Guidelines for Writing and Reading Multi-Page
  107.             TIFF-F Files..............................................33
  108.      4.4.7. Use of TIFF-F for Streaming Applications..................34
  109.    4.5. Implementation Warnings.......................................34
  110.      4.5.1. Uncompressed Data.........................................34
  111.  
  112.  
  113.  
  114. McIntyre, et. al.           Standards Track                     [Page 2]
  115.  
  116. RFC 2301              File Format for Internet Fax            March 1998
  117.  
  118.  
  119.      4.5.2. Encoding and Resolution...................................35
  120.      4.5.3. EOL byte-aligned..........................................35
  121.      4.5.4. EOL.......................................................36
  122.      4.5.5. RTC Exclusion.............................................36
  123.      4.5.6. Use of EOFB for T.6 Compressed Images.....................37
  124.    4.6. Example Use of TIFF-F.........................................37
  125.    4.7. Extended Black-and-white Fax Mode Summary.....................37
  126. 5. Lossless JBIG Black-and-White Fax Mode.............................39
  127.    5.1. Overview......................................................40
  128.    5.2. Required TIFF Fields..........................................40
  129.      5.2.1. Baseline Fields...........................................40
  130.      5.2.2. Extension Fields..........................................40
  131.      5.2.3. New Fields................................................41
  132.    5.3. Recommended TIFF Fields.......................................41
  133.    5.4. Lossless JBIG Black-and-White Mode Summary....................41
  134. 6. Base Color Fax Mode................................................43
  135.    6.1. Overview......................................................43
  136.    6.2. Required TIFF Fields..........................................43
  137.      6.2.1. Baseline Fields...........................................43
  138.      6.2.2. Extension Fields..........................................45
  139.      6.2.3. New Fields................................................46
  140.    6.3. Recommended TIFF Fields.......................................47
  141.    6.4. Base Color Fax Mode Summary...................................47
  142. 7. Lossless Color Mode................................................49
  143.    7.1. Overview......................................................50
  144.      7.1.1. Color Encoding............................................50
  145.      7.1.2. JBIG Encoding.............................................50
  146.    7.2. Required TIFF Fields..........................................51
  147.      7.2.1. Baseline Fields...........................................51
  148.      7.2.2. Extension Fields..........................................52
  149.      7.2.3. New Fields................................................53
  150.    7.3. Recommended TIFF Fields.......................................53
  151.    7.4. Lossless Color Fax Mode Summary...............................53
  152. 8. Mixed Raster Content Mode..........................................55
  153.    8.1 Overview.......................................................55
  154.      8.1.1. MRC 3-layer model.........................................55
  155.      8.1.2. A TIFF Representation for the MRC 3-layer model...........56
  156.    8.2. Required TIFF Fields..........................................58
  157.      8.2.1. Baseline Fields...........................................58
  158.      8.2.2. Extension Fields..........................................59
  159.      8.2.3. New Fields................................................60
  160.    8.3. Recommended TIFF Fields.......................................62
  161.    8.4. Rules and Requirements for Images.............................62
  162.    8.5. MRC Fax Mode Summary..........................................63
  163. 9. MIME content-type image/tiff.......................................66
  164.    9.1 Refinement of MIME content-type image/tiff for Facsimile
  165.        Applications...................................................66
  166. 10. Security Considerations...........................................67
  167.  
  168.  
  169.  
  170. McIntyre, et. al.           Standards Track                     [Page 3]
  171.  
  172. RFC 2301              File Format for Internet Fax            March 1998
  173.  
  174.  
  175. 11. References........................................................67
  176. 12. Authors' Addresses................................................69
  177. Annex A: Summary of TIFF Fields for Internet Fax .....................70
  178. Annex B. IANA Registration for image/tiff Application Parameter
  179.          Values used for facsimile....................................75
  180. Full Copyright Statement..............................................77
  181.  
  182. 1. Introduction
  183.  
  184.    This document describes the use of TIFF (Tag Image File Format) to
  185.    represent the data content and structure generated by the current
  186.    suite of ITU-T Recommendations for Group 3 facsimile. These
  187.    Recommendations and the TIFF fields described here support the
  188.    following facsimile modes or profiles:
  189.  
  190.       S:  minimal black-and-white mode, using binary MH compression
  191.              [T.4]
  192.       F:  extended black-and-white mode, using binary MH, MR and MMR
  193.              compression [T.4, T.6]
  194.       J:  lossless JBIG black-and-white mode, with JBIG compression
  195.              [T.85, T.82]
  196.       C:  lossy color and grayscale mode, using JPEG compression
  197.              [T.42, T.81]
  198.       L:  lossless color and grayscale mode, using JBIG compression
  199.              [T.43, T.82]
  200.       M:  mixed raster content mode [T.44], using a combination of
  201.              existing compression methods
  202.  
  203.    Each profile corresponds to the content of ITU-T Recommendations
  204.    shown and is a subset of the full TIFF for facsimile specification.
  205.  
  206.    Profile S describes a minimal interchange set of fields, which will
  207.    guarantee that, at least, binary black-and-white images will be
  208.    supported. Implementations are required to support this minimal
  209.    interchange set of fields.
  210.  
  211.    With the intent of specifying a file format for Internet Fax, this
  212.    draft:
  213.  
  214.        1.  specifies the structure of TIFF files for facsimile data,
  215.        2.  defines ITU fax-compatible values for existing TIFF fields,
  216.        3.  defines new TIFF fields and values required for compatibility
  217.            with ITU color fax.
  218.  
  219.    This specification of TIFF for facsimile is known as TIFF-FX.
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226. McIntyre, et. al.           Standards Track                     [Page 4]
  227.  
  228. RFC 2301              File Format for Internet Fax            March 1998
  229.  
  230.  
  231. 1.1 Scope
  232.  
  233.    This document defines a TIFF-based file format specification for
  234.    enabling standardized messaging-based fax over the Internet. It
  235.    specifies the TIFF fields and field values required for compatibility
  236.    with the existing ITU-T Recommendations for Group 3 black-and-white,
  237.    grayscale and color facsimile. TIFF has historically been used for
  238.    handling fax image files in applications such as store-and-forward
  239.    messaging.  Implementations that support this file format
  240.    specification for import/export may elect to support it as a native
  241.    format. This document recommends a TIFF file structure that is
  242.    compatible with low-memory and page-level streaming implementations.
  243.  
  244.    Unless otherwise noted, the current TIFF specification [TIFF] and
  245.    selected TIFF Technical Notes [TTN1, TTN2] are the primary references
  246.    for describing TIFF and defining TIFF fields. This document is the
  247.    primary reference for defining TIFF field values for fax
  248.    applications.
  249.  
  250. 1.2 Approach
  251.  
  252.    The basic approach to using TIFF for facsimile data is to insert the
  253.    compressed fax image data in a TIFF file and use TIFF fields to
  254.    encode the parameters that describe the image data. These fields will
  255.    have values that comply with the ITU-T Recommendations. The MIME
  256.    content type of the resulting file will be image/tiff, with an
  257.    optional Application parameter [TIFF-REG]; see Section 9.
  258.  
  259.    This approach takes advantage of TIFF features and structures that
  260.    bridge the data formats and performance requirements of both legacy
  261.    fax machines and host-based fax applications. TIFF constructs for
  262.    pages, images, and strips allow a TIFF file to preserve the fax data
  263.    stream structure and the performance advantages that come with it. A
  264.    TIFF-based approach also builds on an established base of users and
  265.    implementors and ensures backward compatibility with existing TIFF-
  266.    based IETF proposals and work in progress for Internet fax.
  267.  
  268. 1.3 Overview of this draft
  269.  
  270.    Section 2 gives an overview of TIFF. Section 2.1 describes the
  271.    structure of TIFF files, including general guidelines for structuring
  272.    multi-page TIFF files. Section 2.2 lists the TIFF fields that are
  273.    required or recommended for all fax modes. The TIFF fields used only
  274.    by specific fax modes are described in Sections 3-8, which describe
  275.    the individual fax modes. These sections also specify the ITU-
  276.    compatible field values (image parameters) for each mode.
  277.  
  278.  
  279.  
  280.  
  281.  
  282. McIntyre, et. al.           Standards Track                     [Page 5]
  283.  
  284. RFC 2301              File Format for Internet Fax            March 1998
  285.  
  286.  
  287.    The full set of permitted fields of TIFF for facsimile are included
  288.    in the current TIFF specification, Section 2 of this document and the
  289.    sections on specific modes of facsimile operation. This document
  290.    defines profiles of TIFF for facsimile, where a profile is a subset
  291.    of the full set of permitted fields and field values of TIFF for
  292.    facsimile.
  293.  
  294.    Section 3 defines the minimal black-and-white facsimile mode (Profile
  295.    S), which is required in all implementations. Section 4 defines the
  296.    extended black-and-white fax mode (Profile F), which provides a
  297.    standard definition of TIFF-F. Section 5 describes the lossless
  298.    black-and-white mode using JBIG compression (Profile J). Section 6
  299.    defines the base color mode, required in all color implementations,
  300.    for the lossy JPEG representation of color and grayscale facsimile
  301.    data (Profile C). Section 7 defines the lossless JBIG color and
  302.    grayscale facsimile mode (Profile L) and Section 8 defines the Mixed
  303.    Raster Content facsimile mode (Profile M). Each of these sections
  304.    concludes with a table summarizing the required and recommended
  305.    fields for each mode and the values they can have.
  306.  
  307.    Section 9 describes the MIME content type image/tiff and the use of
  308.    the optional Application parameter in connection with TIFF for
  309.    facsimile. Sections 10, 11, 12 and 13 give Security Considerations,
  310.    the ISOC Copyright Notice, References and Authors' Addresses. Annex A
  311.    gives a summary of the TIFF fields used or defined in this document
  312.    and provides a convenient reference for implementors.
  313.  
  314.    To implement only the minimal interchange black-and-white set of
  315.    fields and values (Profile S), one need read only Sections 1, 2, 3, 9
  316.    and 10.
  317.  
  318.    The following tree diagram shows the relationship among profiles and
  319.    between profiles and coding methods.
  320.  
  321.                                 S (MH)
  322.                                / \
  323.                        B&W    /   \   Color
  324.                   ------------     ----------
  325.                  /      \                    \
  326.                 /        F (MMR, MR)          C (JPEG)
  327.                /                             / \
  328.               J (JBIG)                   ----   \
  329.                                         /        \
  330.                                        L (JBIG)   \
  331.                                                    \
  332.                                                     M (MRC)
  333.  
  334.    A profile is based on a collection of ITU-T facsimile coding methods.
  335.  
  336.  
  337.  
  338. McIntyre, et. al.           Standards Track                     [Page 6]
  339.  
  340. RFC 2301              File Format for Internet Fax            March 1998
  341.  
  342.  
  343.    For example, Profile S, the minimal mode, is based on Modified
  344.    Huffman (MH) compression, which are defined in ITU-T Rec. T.4.
  345.    Profile F specifies Modified Read (MR) and Modified Modified Read
  346.    (MMR) compressions, which are defined in ITU-T Rec. T.4 and T.6.
  347.  
  348.    All implementations of TIFF for facsimile MUST implement Profile S,
  349.    which is the root node of the tree. All color implementations of TIFF
  350.    for facsimile MUST implement Profile C. The implementation of a
  351.    particular profile MUST also implement those profiles on the path
  352.    that connect it to the root node, and MAY optionally implement
  353.    profiles not on the path connecting it to the root node. For example,
  354.    an implementation of Profile M must also implement Profiles C and S,
  355.    and may optionally implement Profile F, J or L. For another example,
  356.    an implementation of Profile C must also implement Profile S, and may
  357.    optionally implement Profile F or J.
  358.  
  359.    The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", " NOT",
  360.    "SHOULD", "SHOULD NOT", "RECOMMENDED",  "MAY", and "OPTIONAL" in this
  361.    document are to be interpreted as described in [REQ].
  362.  
  363. 2. TIFF and Fax
  364.  
  365. 2.1. TIFF Overview
  366.  
  367.    TIFF provides a means for describing, storing and interchanging
  368.    raster image data. A primary goal of TIFF is to provide a rich
  369.    environment within which applications can exchange image data. The
  370.    current TIFF specification [TIFF] defines a commonly used, core set
  371.    of TIFF fields known as Baseline TIFF. The current specification and
  372.    TIFF Technical Notes 1 and 2 [TTN1, TTN2] define several TIFF
  373.    extensions. The TIFF- based specification for fax applications uses a
  374.    subset of Baseline TIFF fields, with selected extensions, as
  375.    described in this document. In a few cases, this document defines new
  376.    TIFF fields specifically for fax applications.
  377.  
  378. 2.1.1. File Structure
  379.  
  380.    TIFF is designed for raster images, which makes it a good match for
  381.    facsimile documents, which are multi-page raster images. Each raster
  382.    image consists of a number of rows or scanlines, each of which has
  383.    the same number of pixels, the unit of sampling. Each pixel has at
  384.    least one sample or component (exactly one for black-and-white
  385.    images).
  386.  
  387.    A TIFF file begins with an 8-byte image file header. The first two
  388.    bytes describe the byte order used within the file. Legal values are
  389.    "II" (0x4949) when bytes are ordered from least to most significant
  390.    (little- endian), and "MM" (0x4D4D), when bytes are ordered from most
  391.  
  392.  
  393.  
  394. McIntyre, et. al.           Standards Track                     [Page 7]
  395.  
  396. RFC 2301              File Format for Internet Fax            March 1998
  397.  
  398.  
  399.    to least significant (big-endian) within a 16- or 32-bit integer.
  400.    Either byte order can be used, except in the case of the minimal
  401.    black-and-white mode, which SHALL use value "II". The next two bytes
  402.    contain the value 42 that identifies the file as a TIFF file and is
  403.    ordered according to the value in the first two bytes of the header.
  404.    The last four bytes give the offset that points to the first image
  405.    file directory (IFD). This and all other offsets in a TIFF file are
  406.    with respect to the beginning of the TIFF file. An IFD can be at any
  407.    location in the file after the header but must begin on a word
  408.    boundary.
  409.  
  410.    An IFD is a sequence of tagged fields, sorted in ascending order by
  411.    tag value. An IFD consists of a 2-byte count of the number of fields,
  412.    a sequence of field entries and a 4-byte offset to the next IFD. The
  413.    fields contain information about the image and pointers to the image
  414.    data. Each separate raster image in the file is represented by an
  415.    IFD.
  416.  
  417.    Each field entry in an IFD has 12 bytes and consists of a 2-byte Tag,
  418.    2 bytes identifying the field type (e.g. short, long, rational,
  419.    ASCII), 4 bytes giving the count (number of values or offsets), and 4
  420.    bytes that either contain the offset to a field value stored outside
  421.    the IFD, or, based on the type and count, the field value itself.
  422.    Resolution and metadata such as dates, names and descriptions are
  423.    examples of "long" field values that do not fit in 4 bytes and
  424.    therefore use offsets in the field entry. Details are given in the
  425.    TIFF specification [TIFF].
  426.  
  427.    A TIFF file can contain more than one IFD, where each IFD is a
  428.    subfile whose type is given in the NewSubfileType field. Multiple
  429.    IFDs can be organized either as a linked list, with the last entry in
  430.    each IFD pointing to the next IFD (the pointer in the last IFD is 0),
  431.    or as a tree, using the SubIFDs field in the primary IFD [TTN1]. The
  432.    SubIFDs field contains an array of pointers to child IFDs of the
  433.    primary IFD.
  434.  
  435.    Child IFDs describe related images, such as reduced resolution
  436.    versions of the primary IFD image. The same IFD can point both to a
  437.    next IFD and to child IFDs, and child IFDs can themselves point to
  438.    other IFDs.
  439.  
  440.    All fax modes represent a multi-page fax image as a linked list of
  441.    IFDs, with a NewSubfileType field containing a bit that identifies
  442.    the IFD as one page of a multi-page document. Each IFD has a
  443.    PageNumber field, identifying the page number in ascending order,
  444.    starting at 0 for the first page. While a Baseline TIFF reader is not
  445.  
  446.  
  447.  
  448.  
  449.  
  450. McIntyre, et. al.           Standards Track                     [Page 8]
  451.  
  452. RFC 2301              File Format for Internet Fax            March 1998
  453.  
  454.  
  455.    required to read any IFDs beyond the first, an implementation that
  456.    reads the files that comply with this specification SHALL read
  457.    multiple IFDs. Only the Mixed Raster Content fax mode, described in
  458.    Section 8, requires the use of child IFDs.
  459.  
  460.    The following figure illustrates the structure of a multi-page TIFF
  461.    file.
  462.  
  463.                    +-----------------------+
  464.                    |         Header        |------------+
  465.                    +-----------------------+            | First IFD
  466.                    |      IFD (page 0)     |<-----------+ Offset
  467.                +---|                       |------------+
  468.          Value |   +-----------------------+            |
  469.         Offset +-->|      Long Values      |--+         |
  470.                    +-----------------------|  | Strip   |
  471.                    |       Image Data      |<-+ Offset  |
  472.                    |     strip 1 page 0    |  |         |
  473.                    +-----------------------+  |         |
  474.                    |           :           |  :         |
  475.                                                         |
  476.                    +-----------------------+            | Next IFD
  477.                    |      IFD (page 1)     |<-----------+ Offset
  478.                +---|                       |------------+
  479.          Value |   +-----------------------+            |
  480.         Offset +-->|      Long Values      |--+         |
  481.                    +-----------------------|  | Strip   |
  482.                    |       Image Data      |<-+ Offset  |
  483.                    |     strip 1 page 1    |  |         |
  484.                    +-----------------------+  |         |
  485.                    |     strip 2 page 1    |<-+         |
  486.                    +-----------------------+  |         |
  487.                    |          :            |  :         |
  488.                                                         |
  489.                    +-----------------------+            | Next IFD
  490.                    |      IFD (page 2)     |<-----------+ Offset
  491.                    |          :            |
  492.  
  493. 2.1.2 Image Structure
  494.  
  495.    An IFD stores an image as one or more strips, as shown in the
  496.    preceding figure. A strip consists of 1 or more scanlines (rows) of
  497.    raster image data in compressed form. An image may be stored in a
  498.    single strip or may be divided into several strips, which would
  499.    require less memory to buffer. (Baseline TIFF recommends about 8k
  500.    bytes per strip, but existing fax usage is typically one strip per
  501.    image.)
  502.  
  503.  
  504.  
  505.  
  506. McIntyre, et. al.           Standards Track                     [Page 9]
  507.  
  508. RFC 2301              File Format for Internet Fax            March 1998
  509.  
  510.  
  511.    Each IFD requires three strip-related fields: StripOffsets,
  512.    RowsPerStrip and StripByteCounts. The StripOffsets field is an array
  513.    of pointers to the strip or strips that contain the actual image
  514.    data. The StripByteCounts field gives the number of bytes in each
  515.    strip after compression. TIFF requires that each strip, except the
  516.    last, contain the same number of scanlines, which is given in the
  517.    RowsPerStrip field. This document introduces the new StripRowCounts
  518.    field that allows a variable number of scanlines per strip, which is
  519.    required by the Mixed Raster Content fax mode (Section 8).
  520.  
  521.    Image data is stored as uninterpreted, compressed image data streams
  522.    within a strip. The formats of these streams follow the ITU-T
  523.    Recommendations. The Compression field in the IFD indicates the type
  524.    of compression, and other TIFF fields in the IFD describe image
  525.    attributes, such as color encoding and spatial resolution.
  526.    Compression parameters are stored in the compressed data stream,
  527.    rather than in TIFF fields. This makes the TIFF representation and
  528.    compressed data format specification independent of each another.
  529.    This approach, modeled on [TTN2], allows TIFF to gracefully add new
  530.    compression schemes as they become available.
  531.  
  532.    Some attributes can be specified both in the compressed data stream
  533.    and within a TIFF field. It is possible that the two values will
  534.    differ. When this happens for values required to interpret the data
  535.    stream, then the values in the data stream take precedence. For
  536.    informational values that are not required to interpret the data
  537.    stream, such as author name, then the TIFF field value takes
  538.    precedence.
  539.  
  540. 2.1.3 TIFF File Structure for Fax Applications
  541.  
  542.    The TIFF specification has a very flexible file structure, which does
  543.    not specify the ordering of IFDs, field values and image data in a
  544.    file. Individual applications may require or recommend an ordering.
  545.  
  546.    This specification recommends that when using a TIFF file for
  547.    facsimile, A multi-page fax document SHOULD be represented as a
  548.    linked list of IFDs. It also recommends that a TIFF file for
  549.    facsimile SHOULD order pages in a TIFF file in the same way that they
  550.    are ordered in a fax data stream. In a TIFF file, a page consists of
  551.    several elements: one or more IFDs (including subIFDs), long field
  552.    values that are stored outside the IFDs, and image data (in one or
  553.    more strips).
  554.  
  555.    The minimal black-and-white mode (Profile S) specifies a required
  556.    ordering of pages and elements within a page (Section 3.5). The
  557.    extended black-and-white mode (Profile F) provides guidelines for
  558.    ordering pages and page elements (Section 4.4.6). Other profiles
  559.  
  560.  
  561.  
  562. McIntyre, et. al.           Standards Track                    [Page 10]
  563.  
  564. RFC 2301              File Format for Internet Fax            March 1998
  565.  
  566.  
  567.    SHOULD follow these guidelines. This recommendation is intended to
  568.    simplify the implementation of TIFF writers and readers in fax
  569.    applications and the conversion between TIFF file and fax data stream
  570.    representations. However, for interchange robustness, readers SHOULD
  571.    be prepared to read TIFF files whose structure is consistent with
  572.    [TIFF], which supports a more flexible file structure than is
  573.    recommended here.
  574.  
  575.    This specification introduces an optional new GlobalParametersIFD
  576.    field, defined in Section 2.2.4. This field has type IFD and
  577.    indicates parameters describing the fax session. While it is often
  578.    possible to obtain these parameters by scanning the file, it is
  579.    convenient to make them available together in one place for fast and
  580.    easy access. If the GlobalParametersIFD occurs in a TIFF file, it
  581.    SHOULD be located in the first IFD, immediately following the 8-byte
  582.    image file header.
  583.  
  584. 2.2 TIFF Fields for All Fax Applications
  585.  
  586.    The TIFF specification [TIFF] is organized as a baseline set and
  587.    several extensions, including technical notes [TTN1, TTN2] that will
  588.    be incorporated in the next release of TIFF. The baseline and
  589.    extensions have required and optional fields.
  590.  
  591.    Facsimile applications require (and recommend) a mixture of baseline
  592.    and extensions fields, as well as some new fields that are not part
  593.    of the TIFF specification and that are defined in this document. This
  594.    sub- section lists the fields that are required or recommended for
  595.    all modes. In particular, Section 2.2.1 lists the fields that are
  596.    required by all modes and that have values that do not depend on the
  597.    mode. Section 2.2.2 lists the fields that are required by all modes
  598.    and that have values which do depend on the mode. Section 2.2.3 lists
  599.    the fields that are recommended for all modes. Fields that are
  600.    required or recommended by some but not all modes are given in the
  601.    section (Section 3-8) that describes that mode. The sections for each
  602.    fax mode have sub-sections for required and recommended fields; each
  603.    sub-section organizes the fields according to whether they are
  604.    baseline, extension or new.
  605.  
  606.    The fields required for facsimile have only a few legal values,
  607.    specified in the ITU-T Recommendations. Of these legal values, some
  608.    are required and some are optional, just as they are required
  609.    (mandatory) or optional in fax implementations that conform to the
  610.    ITU-T Recommendations. The required and optional values are noted in
  611.    the sections on the different fax modes.
  612.  
  613.  
  614.  
  615.  
  616.  
  617.  
  618. McIntyre, et. al.           Standards Track                    [Page 11]
  619.  
  620. RFC 2301              File Format for Internet Fax            March 1998
  621.  
  622.  
  623.    This section describes the fields required or recommended by all fax
  624.    modes. The pattern for the description of TIFF fields in this draft
  625.    is:
  626.  
  627. FieldName(TagValueInDecimal) = allowable values.                    TYPE
  628.     WhetherRequiredByTIFForTIFFforFAX
  629.     Count = (omitted if =1) = (if not in current spec but available)
  630.     Explanation of the field, how it's used, and the values it can have.
  631.     Default value, if any, as specified in [TIFF]
  632.  
  633.    When a field's default value is the desired value, that field may be
  634.    omitted from the relevant IFD unless specifically required by the
  635.    text of this specification.
  636.  
  637. 2.2.1.  TIFF fields required for all fax modes
  638.  
  639.    The TIFF fields listed in this section SHALL be used by all fax
  640.    modes, but have field values that are not specified by the ITU
  641.    standards, i.e. the fields do not depend on the mode. The next sub-
  642.    section lists the fields that SHALL be used by all fax modes, but
  643.    which do have values specified by the ITU-specified or mode-specific
  644.    values. Fields that SHALL be used by some but not all modes are given
  645.    in the sections (3-8) which describe the modes that uses them.
  646.  
  647. ImageLength(257)                                           SHORT or LONG
  648.     RequiredByTIFFBaseline
  649.     Total number of scanlines in image.
  650.     No default, must be specified.
  651.  
  652. PageNumber(297)                                                    SHORT
  653.     RequiredByTIFFforFAX, TIFFExtension
  654.     Count = 2
  655.     The first number represents the page number (0 for the first page);
  656.     the second number is the total number of pages in the document. If
  657.     the second value is 0, then the total page count is not available.
  658.     No default, must be specified
  659.  
  660. RowsPerStrip(278)                                          SHORT or LONG
  661.     RequiredByTIFFBaseline
  662.     The number of scanlines per TIFF strip, except for the last strip.
  663.     For a single strip image, this is the same as the value of the
  664.     ImageLength field.
  665.     Default = 2**32 - 1 (meaning all scanlines in one strip)
  666.  
  667. StripByteCounts(279)                                       SHORT or LONG
  668.     RequiredByTIFFBaseline
  669.     Count = number of strips
  670.     For each strip, the number of bytes in that strip after compression.
  671.  
  672.  
  673.  
  674. McIntyre, et. al.           Standards Track                    [Page 12]
  675.  
  676. RFC 2301              File Format for Internet Fax            March 1998
  677.  
  678.  
  679.     No default, must be specified.
  680.  
  681. StripOffsets(273)                                          SHORT or LONG
  682.     RequiredByTIFFBaseline
  683.     Count = number of strips
  684.     For each strip, the byte offset from the beginning of the file to
  685.     the start of that strip.
  686.     No default, must be specified.
  687.  
  688. 2.2.2 Additional TIFF fields required for all fax modes
  689.  
  690.    The TIFF fields listed in this section SHALL be used by all fax
  691.    modes, but the values associated with them depend on the mode being
  692.    described and the associated ITU Recommendations. Therefore, only the
  693.    fields are defined here; the values applicable to a particular fax
  694.    mode are described in Sections 3-8. Fields that SHALL be used by some
  695.    but not all modes are given in the section (3-8) describing the mode
  696.    that uses them.
  697.  
  698. BitsPerSample(258)                                                 SHORT
  699.     RequiredByTIFFBaseline
  700.     Number of bits per image sample
  701.     Default = 1 (field may be omitted if this is the value)
  702.  
  703. Compression(259)                                                   SHORT
  704.     RequiredByTIFFBaseline
  705.     Compression method used for image data
  706.     Default = 1 (no compression, so may not be omitted for FAX)
  707.  
  708. FillOrder(266)                                                     SHORT
  709.     RequiredByTIFFforFax
  710.     The default bit order in Baseline TIFF per [TIFF] is indicated by
  711.     FillOrder=1, where bits are not reversed before being stored.
  712.     However, TIFF for Fax typically utilizes the setting of FillOrder=2,
  713.     where the bit order within bytes is reversed before storage (i.e.,
  714.     bits are stored with the Least Significant Bit first).
  715.     Default = 1 (field may be omitted if this is the value)
  716.     Facsimile data appears on the phone line in bit-reversed order
  717.     relative to its description in the relevant ITU compression
  718.     Recommendation. Therefore, a wide majority of facsimile
  719.     implementations choose this natural order for storage. Nevertheless,
  720.     all readers conforming to this specification must be able to read
  721.     data in both bit orders.
  722.  
  723. ImageWidth(256)                                            SHORT or LONG
  724.     RequiredByTIFFBaseline
  725.     The number of pixels (columns) per scanline (row) of the image
  726.     No default, must be specified.
  727.  
  728.  
  729.  
  730. McIntyre, et. al.           Standards Track                    [Page 13]
  731.  
  732. RFC 2301              File Format for Internet Fax            March 1998
  733.  
  734.  
  735. NewSubFileType(254)                                                 LONG
  736.     RequiredByTIFFforFAX
  737.     A general indication of the kind of data contained in this IFD
  738.     Bit 1 is 1 if the image is a single page of a multi-page document.
  739.     Default = 0 (no subfile bits on, so may not be omitted for FAX)
  740.  
  741. PhotometricInterpretation(262)                                     SHORT
  742.     RequiredByTIFFBaseline
  743.     The color space of the image data
  744.     No default, must be specified
  745.  
  746. ResolutionUnit(296)                                                SHORT
  747.     RequiredByTIFFBaseline
  748.     The unit of measure for resolution. 2 = inch, 3 = centimeter;
  749.     Default = 2 (field may be omitted if this is the value)
  750.  
  751. SamplesPerPixel(277)                                               SHORT
  752.     RequiredByTIFFBaseline
  753.     The number of color components per pixel; SamplesPerPixel is 1 for a
  754.     black-and-white, grayscale or indexed (palette) image.
  755.     Default =1 (field may be omitted if this is the value)
  756.  
  757. XResolution(282)                                                RATIONAL
  758.     RequiredByTIFFBaseline
  759.     The horizontal resolution of the image in pixels per resolution
  760.     unit. The ITU-T Recommendations for facsimile specify a small number
  761.     of horizontal resolutions: 100, 200, 300, 400 pixels per inch, and
  762.     80, 160 pixels per centimeter (or 204, 408 pixels per inch). The
  763.     allowed XResolution values for each mode are given in the section
  764.     defining that mode. Per [T.4], it is permissible for applications to
  765.     treat the following XResolution values as being equivalent: <204,
  766.     200> and <400,408> in pixels/inch. These equivalencies were allowed
  767.     by [T.4] to permit conversions between inch and metric based
  768.     facsimile terminals.
  769.     TIFF for Facsimile Writers SHOULD express XResolution in inch based
  770.     units, for consistency with historical practice and to maximize
  771.     interoperability. See the table below for information on how to
  772.     convert from an ITU-T metric value to its inch based equivalent
  773.     resolution.
  774.     No default, must be specified
  775.  
  776. YResolution(283)                                                RATIONAL
  777.     RequiredByTIFFBaseline
  778.     The vertical resolution of the image in pixels per resolution unit.
  779.     The ITU-T Recommendations for facsimile specify a small number of
  780.     vertical resolutions: 100, 200, 300, 400 pixels per inch, and 38.5,
  781.     77, 154 pixels per centimeter (or 98, 196, 391 pixels per inch). The
  782.     allowed YResolution values for each mode are given in the section
  783.  
  784.  
  785.  
  786. McIntyre, et. al.           Standards Track                    [Page 14]
  787.  
  788. RFC 2301              File Format for Internet Fax            March 1998
  789.  
  790.  
  791.     defining that mode. Per [T.4], it is permissible for applications to
  792.     treat the following YResolution values as being equivalent: <98,
  793.     100>, <196, 200>, and <391, 400> in pixels/inch. These equivalencies
  794.     were allowed by [T.4] to permit conversions between inch and metric
  795.     based facsimile terminals. TIFF for Facsimile Writers SHOULD express
  796.     YResolution in inch based units, for consistency with historical
  797.     practice and to maximize interoperability. See the table below for
  798.     information on how to convert from an ITU-T metric value to its inch
  799.     based equivalent resolution. No default, must be specified
  800.  
  801.       +-----------------------------+-----------------------------+
  802.       |         XResolution         |         YResolution         |
  803.       +--------------+--------------+--------------+--------------+
  804.       |ResolutionUnit|ResolutionUnit|ResolutionUnit|ResolutionUnit|
  805.       |  =2 (inch)   |   =3 (cm)    |  =2 (inch)   |   =3 (cm)    |
  806.       +--------------+--------------+--------------+--------------+
  807.       |     100      |              |     100      |              |
  808.       +--------------+--------------+--------------+--------------+
  809.       |     204      |      80      |      98      |     38.5     |
  810.       |     200      |              |     100      |              |
  811.       +--------------+--------------+--------------+--------------+
  812.       |     204      |      80      |     196      |      77      |
  813.       |     200      |              |     200      |              |
  814.       +--------------+--------------+--------------+--------------+
  815.       |     204      |      80      |     391      |     154      |
  816.       +--------------+--------------+--------------+--------------+
  817.       |     300      |              |     300      |              |
  818.       +--------------+--------------+--------------+--------------+
  819.       |     408      |     160      |     391      |     154      |
  820.       |     400      |              |     400      |              |
  821.       +--------------+--------------+--------------+--------------+
  822.  
  823. 2.2.3 TIFF fields recommended for all fax modes
  824.  
  825.    The TIFF fields listed in this section MAY be used by all fax modes.
  826.    However, Profile S writers (the minimal fax mode described in Section
  827.    3) SHOULD NOT use these fields. Recommended fields that are mode-
  828.    specific are described in Sections 3-8.
  829.  
  830. DateTime(306)                                                      ASCII
  831.     OptionalInTIFFBaseline
  832.     Date/time of image creation in 24-hour format "YYYY:MM:DD HH:MM:SS".
  833.     No default.
  834.  
  835. DocumentName(269)                                                  ASCII
  836.     OptionalInTIFFExtension(DocumentStorageAndRetrieval)
  837.     The name of the scanned document. This is a TIFF extension field,
  838.     not a Baseline TIFF field.
  839.  
  840.  
  841.  
  842. McIntyre, et. al.           Standards Track                    [Page 15]
  843.  
  844. RFC 2301              File Format for Internet Fax            March 1998
  845.  
  846.  
  847.     No default.
  848.  
  849. ImageDescription(270)                                              ASCII
  850.     OptionalInTIFFBaseline
  851.     A string describing the contents of the image.
  852.     No default.
  853.  
  854. Orientation(274) = 1-8.                                            SHORT
  855.     OptionalinTIFFBaseline
  856.     1: 0th row represents the visual top of the image; the 0th column
  857.     represents the visual left side of the image. See the current TIFF
  858.     spec [TIFF] for further values; Baseline TIFF only requires value=1.
  859.     Default = 1.
  860.     Note: It is recommended that a writer that is aware of the
  861.     orientation will include this field to give a positive indication of
  862.     the orientation, even if the value is the default. If the
  863.     Orientation field is omitted, the reader SHALL assume a value of 1.
  864.  
  865. Software(305)                                                      ASCII
  866.     OptionalInTIFFBaseline
  867.     The optional name and release number of the software package that
  868.     created the image.
  869.     No default.
  870.  
  871. 2.2.4 New TIFF fields recommended for fax modes
  872.  
  873.    The new TIFF fields listed in this section MAY be used by all fax
  874.    modes, but their support is not expected for the minimal fax mode
  875.    described in Section 3. In addition, support for these new TIFF
  876.    fields has not been included in historical TIFF-F readers described
  877.    in Section 4 and [TIFF- F]. These fields describe "global" parameters
  878.    of the fax session that created the image data. They are optional,
  879.    not part of the current TIFF specification, and are defined in this
  880.    document.
  881.  
  882.    The first new field, GlobalParametersIFD, is an IFD that contains
  883.    global parameters and is located in a Primary IFD.
  884.  
  885. GlobalParametersIFD (400)                                            IFD
  886.     An IFD containing global parameters. It is recommended that a TIFF
  887.     writer place this field in the first IFD, where a TIFF reader would
  888.     find it quickly.
  889.  
  890.    Each field in the GlobalParametersIFD is a TIFF field that is legal
  891.    in any IFD. Required baseline fields should not be located in the
  892.    GlobalParametersIFD, but should be in each image IFD. If a conflict
  893.    exists between fields in the GlobalParametersIFD and in the image
  894.    IFDs, then the data in the image IFD shall prevail.
  895.  
  896.  
  897.  
  898. McIntyre, et. al.           Standards Track                    [Page 16]
  899.  
  900. RFC 2301              File Format for Internet Fax            March 1998
  901.  
  902.  
  903.    Among the GlobalParametersIFD entries is a new ProfileType field
  904.    which generally describes information in this IFD and in the TIFF
  905.    file.
  906.  
  907. ProfileType(401)                                                    LONG
  908.     The type of image data stored in this IFD.
  909.     0 = Unspecified
  910.     1 = Group 3 fax
  911.     No default
  912.  
  913.    The following new global fields are defined in this document as IFD
  914.    entries for use with fax applications.
  915.  
  916. FaxProfile(402) = 0 - 6.                                            BYTE
  917.     The profile that applies to this file; a profile is subset of the
  918.     full set of permitted fields and field values of TIFF for facsimile.
  919.     The currently defined values are:
  920.     0: does not conform to a profile defined for TIFF for facsimile
  921.     1: minimal black & white lossless, Profile S
  922.     2: extended black & white lossless, Profile F
  923.     3: lossless JBIG black & white, Profile J
  924.     4: lossy color and grayscale, Profile C
  925.     5: lossless color and grayscale, Profile L
  926.     6: Mixed Raster Content, Profile M
  927.  
  928. CodingMethods(403)                                                  LONG
  929.     This field indicates which coding methods are used in the file. A
  930.     bit value of 1 indicates which of the following coding methods is
  931.     used:
  932.     Bit 0: unspecified compression,
  933.     Bit 1: 1-dimensional coding, ITU-T Rec. T.4 (MH - Modified Huffman),
  934.     Bit 2: 2-dimensional coding, ITU-T Rec. T.4 (MR - Modified Read),
  935.     Bit 3: 2-dimensional coding, ITU-T Rec. T.6 (MMR - Modified MR),
  936.     Bit 4: ITU-T Rec. T.82 coding, using ITU-T Rec. T.85 (JBIG),
  937.     Bit 5: ITU-T Rec. T.81 (Baseline JPEG),
  938.     Bit 6: ITU-T Rec. T.82 coding, using ITU-T Rec. T.43 (JBIG color),
  939.     Bits 7-31: reserved for future use
  940.     Note: There is a limit of 32 compression types to identify standard
  941.     compression methods.
  942.  
  943. VersionYear(404)                                                    BYTE
  944.     Count: 4
  945.     The year of the standard specified by the FaxProfile field, given as
  946.     4 characters, e.g. '1997'; used in lossy and lossless color modes.
  947.  
  948. ModeNumber (405)                                                    BYTE
  949.     The mode of the standard specified by the FaxProfile field. A
  950.     value of 0 indicates Mode 1.0; used in Mixed Raster Content mode.
  951.  
  952.  
  953.  
  954. McIntyre, et. al.           Standards Track                    [Page 17]
  955.  
  956. RFC 2301              File Format for Internet Fax            March 1998
  957.  
  958.  
  959. 3. Minimal Black-and-White Fax Mode
  960.  
  961.    This section defines the minimal black-and-white subset of TIFF for
  962.    facsimile. This subset is designated Profile S. All implementations
  963.    of TIFF for facsimile SHALL support the minimal subset.
  964.  
  965.    Black-and-white mode is the binary fax application most users are
  966.    familiar with today. This mode is appropriate for black-and-white
  967.    text and line art. Black-and-white mode is divided into two levels of
  968.    capability. This section describes the minimal interchange set of
  969.    TIFF fields that must be supported by all implementations in order to
  970.    assure that some form of image, albeit black-and-white, can be
  971.    interchanged. This minimum interchange set is a strict subset of the
  972.    fields and values defined for the extended black-and-white mode
  973.    (TIFF-F or Profile F) in Section 4, which describes extensions to the
  974.    minimal interchange set of fields that provide a richer set of
  975.    black-and-white capabilities.
  976.  
  977. 3.1. Overview
  978.  
  979.    The minimal interchange portion of the black-and-white facsimile mode
  980.    supports 1-dimensional Modified Huffman (MH) compression, with the
  981.    original Group 3 fax resolutions, commonly called "standard" and
  982.    "fine."
  983.  
  984.    To assure interchange, this mode uses the minimal set of fields, with
  985.    a minimal set of values. There are no recommended fields in this
  986.    mode. Further, the TIFF file is required to be "little endian," which
  987.    means that the byte order value in the TIFF header is "II". This mode
  988.    defines a required ordering for the pages in a fax document and for
  989.    the IFDs and image data of a page. It also requires that a single
  990.    strip contain the image data for each page; see Section 3.5. The
  991.    image data may contain RTC sequences, as specified in Section 3.4.
  992.  
  993. 3.2. Required TIFF Fields
  994.  
  995.    Besides the fields listed in Section 2.2.1, the minimal black-and-
  996.    white fax mode requires the following fields. The fields listed in
  997.    Section 2.2.1 and the fields and fax-specific values specified in
  998.    this sub- section must be supported by all implementations.
  999.  
  1000. 3.2.1 Baseline fields
  1001.  
  1002. BitsPerSample(258) = 1.                                            SHORT
  1003.     RequiredByTIFFBaseline
  1004.     Binary data only.
  1005.     Default = 1 (field may be omitted if this is the value)
  1006.  
  1007.  
  1008.  
  1009.  
  1010. McIntyre, et. al.           Standards Track                    [Page 18]
  1011.  
  1012. RFC 2301              File Format for Internet Fax            March 1998
  1013.  
  1014.  
  1015. Compression(259) = 3.                                              SHORT
  1016.     RequiredByTIFFBaseline
  1017.     3 = 1- or 2- dimensional coding.
  1018.     The value 3 is a TIFF extension value [TIFF]. The T4Options field
  1019.     must be specified and its value specifies that the data is encoded
  1020.     using the Modified Huffman (MH) encoding of [T.4].
  1021.  
  1022. FillOrder(266) = 2.                                                SHORT
  1023.     RequiredByTIFFBaseline
  1024.     2 = Least Significant Bit first
  1025.  
  1026.    NOTE: Baseline TIFF readers are only required to support FillOrder =
  1027.    1, where the lowest numbered pixel is stored in the MSB of the byte.
  1028.    However, because many devices, such as modems, transmit the LSB first
  1029.    when converting the data to serial form, it is common for black-and-
  1030.    white fax products to use the second FillOrder =2, where the lowest
  1031.    numbered pixel is stored in the LSB. Therefore, this value is
  1032.    specified in the minimal black-and-white mode.
  1033.  
  1034. ImageWidth(256) = 1728.                                    SHORT or LONG
  1035.     RequiredByTIFFBaseline
  1036.     This mode only supports a page width of 1728 pixels. This width
  1037.     corresponds to North American Letter and Legal and to ISO A4 size
  1038.     pages.
  1039.     No default, must be specified.
  1040.  
  1041. NewSubFileType(254) = (Bit 1=1).                                    LONG
  1042.     RequiredByTIFFforFAX
  1043.     Bit 1 is 1 if the image is a single page of a multi-page document.
  1044.     Default = 0 (no subfile bits on, so may not be omitted for fax)
  1045.  
  1046. PhotometricInterpretation(262) = 0.                                SHORT
  1047.     RequiredByTIFFBaseline
  1048.     0 = pixel value 1 means black
  1049.     No default, must be specified
  1050.  
  1051. ResolutionUnit(296) = 2.                                           SHORT
  1052.     RequiredByTIFFBaseline
  1053.     The unit of measure for resolution. 2 = inch.
  1054.     Default = 2 (field may be omitted if this is the value)
  1055.  
  1056. SamplesPerPixel(277) = 1.                                          SHORT
  1057.     RequiredByTIFFBaseline
  1058.     The number of components per pixel; 1 for black-and-white
  1059.     Default =1 (field may be omitted if this is the value)
  1060.  
  1061. XResolution(282) = 200, 204.                                    RATIONAL
  1062.     RequiredByTIFFBaseline
  1063.  
  1064.  
  1065.  
  1066. McIntyre, et. al.           Standards Track                    [Page 19]
  1067.  
  1068. RFC 2301              File Format for Internet Fax            March 1998
  1069.  
  1070.  
  1071.     The horizontal resolution of the image is expressed in pixels per
  1072.     resolution unit. In pixels/inch, the allowed values are 200 and 204,
  1073.     which may be treated as equivalent. See Section 2.2.2 for inch-
  1074.     metric equivalency.
  1075.     No default, must be specified
  1076.  
  1077. YResolution(283) = 98, 100, 196, 200.                           RATIONAL
  1078.     RequiredByTIFFBaseline
  1079.     The vertical resolution of the image is expressed in pixels per
  1080.     resolution unit. In pixels/inch, the allowed values are 98, 100,
  1081.     196 and 200; 98 and 100 may be treated as equivalent, and 196 and
  1082.     200 may be treated as equivalent. See Section 2.2.2 for inch-metric
  1083.     equivalency.
  1084.     No default, must be specified
  1085.  
  1086. 3.2.2 Extension fields
  1087.  
  1088. T4Options(292) = (Bit 0 = 0, Bit 1 = 0, Bit 2 = 0, 1)               LONG
  1089.     RequiredTIFFExtension (when Compression = 3)
  1090.     Bit 0 = 0 indicates MH encoding.
  1091.     Bit 1 must be 0
  1092.     Bit 2 = 1 indicates that EOLs are byte aligned, = 0 EOLs not byte
  1093.     aligned
  1094.     Default is all bits are 0 (applies when EOLs are not byte aligned)
  1095.  
  1096.    Note: The T4Options field is required when the Compression field has
  1097.    a value of 3. Bit 0 of this field specifies the encoding used (MH
  1098.    only in this mode) and Bit 2 indicates whether the EOL codes are
  1099.    byte-aligned or not. If they are byte aligned, then fill bits have
  1100.    been added as necessary so that the End of Line (EOL) codes always
  1101.    end on byte boundaries. See Section 3.4 for details.
  1102.  
  1103. 3.2.3. New Fields
  1104.  
  1105.    None.
  1106.  
  1107. 3.3. Recommended TIFF Fields
  1108.  
  1109.    None.
  1110.  
  1111. 3.4. End of Line (EOL) and Return to Control (RTC)
  1112.  
  1113.    The handling of End of Line (EOL) codes and Return to Control (RTC)
  1114.    sequences illustrate the differences between conventional fax, which
  1115.    is bit and stream oriented, and TIFF, which is byte and file
  1116.    oriented. Conventional fax, Baseline TIFF and TIFF extensions for fax
  1117.    all handle EOLs and RTCs differently.
  1118.  
  1119.  
  1120.  
  1121.  
  1122. McIntyre, et. al.           Standards Track                    [Page 20]
  1123.  
  1124. RFC 2301              File Format for Internet Fax            March 1998
  1125.  
  1126.  
  1127.    In conventional fax, an MH-compressed fax data stream for a page
  1128.    consists of the following sequence:
  1129.  
  1130.       EOL, compressed data (first line), EOL, compressed data, ... ,
  1131.       EOL, compressed data (last line), RTC (6 consecutive EOL codes)
  1132.  
  1133.    Baseline TIFF does not use EOL codes or Return to Control (RTC)
  1134.    sequences for MH-compressed data. However, the TIFF extension field
  1135.    T4Options used in this specification for MH compression (Compression
  1136.    = 3) requires EOLs.
  1137.  
  1138.    Furthermore, Bit 2 in the T4Options field indicates whether or not
  1139.    the EOL codes are byte aligned. If Bit 2 = 1, indicating the EOL
  1140.    codes are byte aligned, then fill bits have been added as necessary
  1141.    before EOL codes so that an EOL code always ends on a byte boundary,
  1142.    and the first bit of data following an EOL begins on a byte boundary.
  1143.    Without fill bits, an EOL code may end in the middle of a byte. Byte
  1144.    alignment relieves application software of the burden of bit-shifting
  1145.    every byte while parsing scan lines for line-oriented image
  1146.    manipulation (such as writing a TIFF file). Not all TIFF readers
  1147.    historically used for fax are able to deal with non-byte aligned
  1148.    data.
  1149.  
  1150.    While TIFF extension requires EOL codes, TIFF in fax applications has
  1151.    traditionally prohibited RTC sequences. Implementations that want
  1152.    common processing and interfaces for fax data streams and Internet
  1153.    fax files would prefer that the TIFF data include RTC sequences.
  1154.  
  1155.    To reconcile these differences, RTCs are allowed in cases where EOL
  1156.    codes are not byte aligned and no fill bits have been added to the
  1157.    data. This corresponds to situations where the fax data is simply
  1158.    inserted in a strip without being processed or interpreted. RTCs
  1159.    should not occur in the data when EOLs have been byte aligned. This
  1160.    is formally specified in the next sub-section.
  1161.  
  1162. 3.4.1. RTC Exclusion
  1163.  
  1164.    Implementations which wish to maintain strict conformance with TIFF
  1165.    and compatibility with the historical use of TIFF for fax SHOULD NOT
  1166.    include the RTC sequence when writing TIFF files. However,
  1167.    implementations which need to support "transparency" of T.4-generated
  1168.    image data MAY include RTCs when writing TIFF files if the flag
  1169.    settings of the T4Options field are set for non-byte aligned data,
  1170.    i.e. Bit 2 is 0. Implementors of TIFF readers should be aware that
  1171.    there are some existing TIFF implementations for fax that include the
  1172.    RTC sequence in MH image data. Therefore, minimal set readers MUST be
  1173.    able to process files which do not include RTCs and SHOULD be able to
  1174.    process files which do include RTCs.
  1175.  
  1176.  
  1177.  
  1178. McIntyre, et. al.           Standards Track                    [Page 21]
  1179.  
  1180. RFC 2301              File Format for Internet Fax            March 1998
  1181.  
  1182.  
  1183. 3.5. File Structure
  1184.  
  1185.    The TIFF header, described in Section 2.1.1, contains two bytes which
  1186.    describe the byte order used within the file. For the minimal black-
  1187.    and- white mode, these bytes SHALL have the value "II" (0x4949),
  1188.    denoting that the bytes in the TIFF file are in LSByte-first order
  1189.    (little- endian). The first or 0th IFD immediately follows the
  1190.    header, so that offset to the first IFD is 8. The headers values are
  1191.    shown in the following table:
  1192.  
  1193.           +--------+-------------------+--------+-----------+
  1194.           | Offset |   Description     |     Value          |
  1195.           +--------+-------------------+--------+-----------+
  1196.           |   0    |   Byte Order      |  0x4949 (II)       |
  1197.           +--------+-------------------+--------+-----------+
  1198.           |   2    |   Identifier      |  42 decimal        |
  1199.           +--------+-------------------+--------+-----------+
  1200.           |   4    | Offset of 0th IFD |  0x 0000 0008      |
  1201.           +--------+-------------------+--------+-----------+
  1202.  
  1203.    The minimal black-and-white mode SHALL order IFDs and image data
  1204.    within a file as follows: 1) there SHALL be an IFD for each page in a
  1205.    multi- page fax document; (2) the IFDs SHALL occur in the same order
  1206.    in the file as the pages occur in the document; (3) the IFD SHALL
  1207.    precede the image data to which it has offsets; (4) the image data
  1208.    SHALL occur in the same order in the file as the pages occur in the
  1209.    document; (5) the IFD, the value data and the image data it has
  1210.    offsets to SHALL precede the next image IFD; and (6) the image data
  1211.    for each page SHALL be contained within a single strip.
  1212.  
  1213.    As a result of (6), the StripOffsets field will contain the pointer
  1214.    to the image data. With two exceptions, the field entries in the IFD
  1215.    contain the field values instead of offsets to field values located
  1216.    outside the IFD. The two exceptions are the values for the
  1217.    XResolution and YResolution fields, both of which are type RATIONAL
  1218.    and require 2 4- byte numbers. These "long" field values SHALL be
  1219.    placed immediately after  the IFD which contains the offsets to them,
  1220.    and before the image data pointed to by that IFD.
  1221.  
  1222.    The effect of these requirements is that the IFD for the first page
  1223.    SHALL come first in the file after the TIFF header, followed by the
  1224.    long field values for XResolution and YResolution, followed by the
  1225.    image data for the first page, then the IFD for second page, etc.
  1226.    This is shown in the following figure. Each IFD is required to have a
  1227.    PageNumber field, which has value 0 for the first page, 1 for the
  1228.    second page, and so on.
  1229.  
  1230.  
  1231.  
  1232.  
  1233.  
  1234. McIntyre, et. al.           Standards Track                    [Page 22]
  1235.  
  1236. RFC 2301              File Format for Internet Fax            March 1998
  1237.  
  1238.  
  1239.                    +-----------------------+
  1240.                    |         Header        |------------+
  1241.                    +-----------------------+            | First IFD
  1242.                    |      IFD (page 0)     | <----------+ Offset
  1243.                +---|                       |------------+
  1244.                |   |                       |--+         |
  1245.          Value |   +-----------------------+  |         |
  1246.         Offset +-->|      Long Values      |  |         |
  1247.                    +-----------------------|  | Strip   |
  1248.                    |  Image Data (page 0)  |<-+ Offset  |
  1249.                    +-----------------------+            | Next IFD
  1250.                    |      IFD (page 1)     | <----------+ Offset
  1251.                +---|                       |------------+
  1252.                |   |                       |--+         |
  1253.          Value |   +-----------------------+  |         |
  1254.         Offset +-->|      Long Values      |  |         |
  1255.                    +-----------------------|  | Strip   |
  1256.                    |  Image Data (page 1)  |<-+ Offset  |
  1257.                    +-----------------------+            | Next IFD
  1258.                    |      IFD (page 2)     | <----------+ Offset
  1259.                    +-----------------------+
  1260.                    |          :            |
  1261.  
  1262.    Using this file structure may reduce the memory requirements in
  1263.    implementations. It is also provides some support for streaming, in
  1264.    which a file can be processed as it is received and before the entire
  1265.    file is received.
  1266.  
  1267. 3.6 Minimal Black-and-white Mode Summary
  1268.  
  1269.    The table below summarizes the TIFF fields that comprise the minimal
  1270.    interchange set for black-and-white facsimile. The Baseline and
  1271.    Extension fields and field values MUST be supported by all
  1272.    implementations. For convenience in the table, certain fields which
  1273.    have a value that is a sequence of flag bits are shown taking integer
  1274.    values that correspond to the flags that are set. An implementation
  1275.    should test the setting of the relevant flag bits individually,
  1276.    however, to allow extensions to the sequence of flag bits to be
  1277.    appropriately ignored. (See, for example, T4Options below.)
  1278.  
  1279.       +---------------------------+--------------------------------+
  1280.       | Baseline Fields           |  Values                        |
  1281.       +---------------------------+--------------------------------+
  1282.       | BitsPerSample             | 1                              |
  1283.       +---------------------------+--------------------------------+
  1284.       | Compression               | 3: 1D Modified Huffman coding  |
  1285.       |                           |     set T4Options = 0 or 4     |
  1286.       +------------------------------------------------------------+
  1287.  
  1288.  
  1289.  
  1290. McIntyre, et. al.           Standards Track                    [Page 23]
  1291.  
  1292. RFC 2301              File Format for Internet Fax            March 1998
  1293.  
  1294.  
  1295.       +---------------------------+--------------------------------+
  1296.       | FillOrder                 | 2: least significant bit first |
  1297.       +---------------------------+--------------------------------+
  1298.       | ImageWidth                | 1728                           |
  1299.       +---------------------------+--------------------------------+
  1300.       | ImageLength               | n: total number of scanlines   |
  1301.       |                           | in image                       |
  1302.       +---------------------------+--------------------------------+
  1303.       | NewSubFileType            | 2: Bit 1 identifies single     |
  1304.       |                           | page of a multi-page document  |
  1305.       +---------------------------+--------------------------------+
  1306.       | PageNumber                | n,m: page number n followed by |
  1307.       |                           | total page count m             |
  1308.       +---------------------------+--------------------------------+
  1309.       | PhotometricInterpretation | 0: pixel value 1 means black   |
  1310.       +---------------------------+--------------------------------+
  1311.       | ResolutionUnit            | 2: inch                        |
  1312.       +---------------------------+--------------------------------+
  1313.       | RowsPerStrip              | number of scanlines per strip  |
  1314.       |                           | = ImageLength, with one strip  |
  1315.       +---------------------------+--------------------------------+
  1316.       | SamplesPerPixel           | 1                              |
  1317.       +---------------------------+--------------------------------+
  1318.       | StripByteCounts           | number of bytes in TIFF strip  |
  1319.       +---------------------------+--------------------------------+
  1320.       | StripOffsets              | offset from beginning of       |
  1321.       |                           | file to single TIFF strip      |
  1322.       +---------------------------+--------------------------------+
  1323.       | XResolution               | 204, 200 (pixels/inch)         |
  1324.       +---------------------------+--------------------------------+
  1325.       | YResolution               | 98, 196, 100, 200 (pixels/inch)|
  1326.       +---------------------------+--------------------------------+
  1327.       | Extension Fields                                           |
  1328.       +---------------------------+--------------------------------+
  1329.       | T4Options                 | 0: MH coding, EOLs not byte    |
  1330.       |                           |               aligned          |
  1331.       |                           | 4: MH coding, EOLs byte aligned|
  1332.       +---------------------------+--------------------------------+
  1333.  
  1334. 4. Extended Black-and-White fax mode
  1335.  
  1336.    This section defines the extended black-and-white mode or Profile F
  1337.    of TIFF for facsimile. It provides a standard definition of what has
  1338.    historically been known as TIFF Class F and now TIFF-F. In doing so,
  1339.    it aligns this mode with current ITU-T Recommendations for black-
  1340.    and-white fax and with existing industry practice. Implementations of
  1341.    this profile include implementations of Profile S.
  1342.  
  1343.  
  1344.  
  1345.  
  1346. McIntyre, et. al.           Standards Track                    [Page 24]
  1347.  
  1348. RFC 2301              File Format for Internet Fax            March 1998
  1349.  
  1350.  
  1351.    This section describes extensions to the minimal interchange set of
  1352.    fields (Profile S) that provide a richer set of black-and-white
  1353.    capabilities. The fields and values described in this section are a
  1354.    superset of the fields and values defined for the minimal interchange
  1355.    set in Section 3. In addition to the MH encoding, Modified READ (MR)
  1356.    and Modified Modified READ (MMR) encoding as described in [T.4] and
  1357.    [T.6] are supported.
  1358.  
  1359.    Section 4.1 gives an overview of TIFF-F. Section 4.2 describes the
  1360.    TIFF fields that SHALL be used in this mode. Section 4.3 describes
  1361.    the fields that MAY be used in this mode. In the spirit of the
  1362.    original TIFF-F specification, Sections 4.4 and 4.5 discuss technical
  1363.    implementation issues and warnings. Section 4.6 gives an example use
  1364.    of TIFF-F. Section 4.7 gives a summary of the required and
  1365.    recommended fields and their values.
  1366.  
  1367. 4.1 TIFF-F Overview
  1368.  
  1369.    Though it has been in common usage for many years, TIFF-F has
  1370.    previously never been documented in the form of a standard.  An
  1371.    informal TIFF-F document was originally created by a small group of
  1372.    fax experts led by Joe Campbell.  The existence of TIFF-F is noted in
  1373.    [TIFF] but it is not defined.  This document serves as the formal
  1374.    definition of the F application of [TIFF] for Internet applications.
  1375.    For ease of reference, the term TIFF-F will be used throughout this
  1376.    document as a shorthand for the extended black-and-white mode or
  1377.    profile of TIFF for facsimile.
  1378.  
  1379.    Up until the TIFF 6.0 specification, TIFF supported various "Classes"
  1380.    which defined the use of TIFF for various applications. Classes were
  1381.    used to support specific applications. In this spirit, TIFF-F has
  1382.    been known historically as "TIFF Class F".  Previous informal TIFF-F
  1383.    documents [TIFF-F0] used the "Class F" terminology.  As of TIFF 6.0
  1384.    [TIFF], the TIFF Class concept has been eliminated in favor of the
  1385.    concept of Baseline TIFF.  Therefore, this document updates the
  1386.    definition of TIFF-F as the F profile of TIFF for facsimile, by using
  1387.    Baseline  TIFF as defined in [TIFF] as the starting point and then
  1388.    adding the TIFF extensions to Baseline TIFF which apply for TIFF-F.
  1389.    In almost all  cases, the resulting definition of TIFF-F fields and
  1390.    values remains  consistent with those used historically in earlier
  1391.    definitions of TIFF  Class F.  Where some of the values for fields
  1392.    have been updated to provide more precise conformance with the ITU-T
  1393.    [T.4] and [T.30] fax recommendations, these differences are noted.
  1394.  
  1395.  
  1396.  
  1397.  
  1398.  
  1399.  
  1400.  
  1401.  
  1402. McIntyre, et. al.           Standards Track                    [Page 25]
  1403.  
  1404. RFC 2301              File Format for Internet Fax            March 1998
  1405.  
  1406.  
  1407. 4.2. Required TIFF Fields
  1408.  
  1409.    This section lists the required fields and the values they must have
  1410.    to be ITU-compatible. Besides the fields listed in Section 2.2.1, the
  1411.    extended black-and-white fax mode SHALL use the following fields.
  1412.  
  1413. 4.2.1. Baseline fields
  1414.  
  1415. BitsPerSample(258) = 1.                                            SHORT
  1416.     RequiredByTIFFBaseline
  1417.     Binary data only.
  1418.     Default = 1 (field may be omitted if this is the value)
  1419.  
  1420. Compression(259) = 3, 4.                                           SHORT
  1421.     RequiredByTIFFBaseline
  1422.     3 = 1- or 2- dimensional coding, must have T4Options field This is
  1423.     a TIFF Extension value [TIFF].
  1424.     4 = 2-dimensional coding, ITU-T Rec. T.6 (MMR - Modified Modified
  1425.     Read, must have T6Options field)) This is a TIFF Extension value.
  1426.     Default = 1 (and is not applicable; field must be specified)
  1427.  
  1428.    NOTE: Baseline TIFF permits use of value 2 for Modified Huffman
  1429.    encoding, but data is presented in a form which does not use EOLs,
  1430.    and so TIFF for facsimile uses Compression=3 instead. See Sections
  1431.    4.4.4, 4.5.1 and 4.5.2 for more information on compression and
  1432.    encoding.
  1433.  
  1434. FillOrder(266) = 1 , 2.                                            SHORT
  1435.     RequiredByTIFFBaseline
  1436.     Profile F readers must be able to read data in both bit orders,
  1437.     but the vast majority of facsimile products store data LSB
  1438.     first, exactly as it appears on the telephone line.
  1439.               1 = Most Significant Bit first.
  1440.               2 = Least Significant Bit first
  1441.  
  1442. ImageWidth(256)                                            SHORT or LONG
  1443.     RequiredByTIFFBaseline
  1444.     This mode supports the following fixed page widths: 1728, 2592, 3456
  1445.     (corresponding to North American Letter and Legal, ISO A4 paper
  1446.     sizes), 2048, 3072, 4096 (corresponding to ISO B4 paper size), and
  1447.     2432, 3648, 4864 (corresponding to ISO A3 paper size).
  1448.     No default; must be specified
  1449.  
  1450.    NOTE: Historical TIFF-F did not include support for the following
  1451.    widths related to higher resolutions: 2592, 3072, 3648, 3456, 4096
  1452.    and 4864. Historical TIFF-F documents also included the following
  1453.    values related to A5 and A6 widths: 816 and 1216. Per the most recent
  1454.  
  1455.  
  1456.  
  1457.  
  1458. McIntyre, et. al.           Standards Track                    [Page 26]
  1459.  
  1460. RFC 2301              File Format for Internet Fax            March 1998
  1461.  
  1462.  
  1463.    version of [T.4], A5 and A6 documents are no longer supported in
  1464.    Group 3 facsimile, so the related width values are now obsolete. See
  1465.    section 4.5.2 for more information on inch/metric equivalencies and
  1466.    other implementation details.
  1467.  
  1468. NewSubFileType(254) = (Bit 1=1).                                    LONG
  1469.     RequiredByTIFFforFAX
  1470.     Bit 1 is 1 if the image is a single page of a multi-page document.
  1471.     Default = 0 (no subfile bits on, so may not be omitted for fax)
  1472.  
  1473.    NOTE: Bit 1 is always set to 1 for TIFF-F, indicating a single page
  1474.    of a multi-page image. The same bit settings are used when TIFF-F is
  1475.    used for a one page fax image. See Section 4.4.3 for details on
  1476.    multi-page files.
  1477.  
  1478. PhotometricInterpretation(262) = 0, 1.                             SHORT
  1479.     RequiredByTIFFBaseline
  1480.     0 = pixel value 1 means black, 1 = pixel value 1 means white.
  1481.     This field allows notation of an inverted or negative image.
  1482.     No default, must be specified
  1483.  
  1484. ResolutionUnit(296) = 2, 3.                                        SHORT
  1485.     RequiredByTIFFBaseline
  1486.     The unit of measure for resolution. 2 = inch, 3 = centimeter; TIFF-F
  1487.     has traditionally used inch-based measures.
  1488.     Default = 2 (field may be omitted if this is the value)
  1489.  
  1490. SamplesPerPixel(277) = 1.                                          SHORT
  1491.     RequiredByTIFFBaseline
  1492.     1 = monochrome, bilevel in this case (see BitsPerSample)
  1493.     Default =1 (field may be omitted if this is the value)
  1494.  
  1495. XResolution(282) = 200, 204, 300, 400, 408                      RATIONAL
  1496.     RequiredByTIFFBaseline
  1497.     The horizontal resolution of the image is expressed in pixels per
  1498.     resolution unit. In pixels/inch, the allowed values are: 200, 204,
  1499.     300, 400, and 408. See Section 2.2.2 for inch-metric equivalency.
  1500.     No default, must be specified
  1501.  
  1502.    NOTE: The values of 200 and 408 have been added to the historical
  1503.    TIFF-F values, for consistency with [T.30]. Some existing TIFF-F
  1504.    implementations may also support values of 80 pixels/cm, which is
  1505.    equivalent to 204 pixels per inch. See section 4.5.2 for information
  1506.    on implementation details.
  1507.  
  1508. YResolution(283) = 98, 100, 196, 200, 300, 391, and 400       RATIONAL
  1509.     RequiredByTIFFBaseline
  1510.     The vertical resolution of the image is expressed in pixels per
  1511.  
  1512.  
  1513.  
  1514. McIntyre, et. al.           Standards Track                    [Page 27]
  1515.  
  1516. RFC 2301              File Format for Internet Fax            March 1998
  1517.  
  1518.  
  1519.     resolution unit. In pixels/inch, the allowed values are: 98, 100,
  1520.     196, 200, 300, 391, and 400 pixels/inch.
  1521.     See Section 2.2.2 for inch-metric equivalency.
  1522.     No default, must be specified
  1523.  
  1524.    NOTE: The values of 100, 200, and 391 have been added to the
  1525.    historical TIFF-F values, for consistency with [T.30].  Some existing
  1526.    TIFF-F implementations may also support values of 77 and 38.5 (cm),
  1527.    which are equivalent to 196 and 98 pixels per inch respectively. See
  1528.    section 4.5.2 for more information on implementation details.
  1529.  
  1530.    NOTE: Not all combinations of XResolution, YResolution and ImageWidth
  1531.    are legal. The following table gives the legal combinations and
  1532.    corresponding paper size [T.30].
  1533.  
  1534.     +--------------+-----------------+---------------------------+
  1535.     |   XResolution x YResolution    |         ImageWidth        |
  1536.     +--------------+-----------------+---------+--------+--------+
  1537.     |      200x100, 204x98           |         |        |        |
  1538.     |      200x200, 204x196          |  1728   |  2048  |  2432  |
  1539.     |           204x391              |         |        |        |
  1540.     +--------------+-----------------+---------+--------+--------+
  1541.     |          300 x 300             |  2592   |  3072  |  3648  |
  1542.     +--------------+-----------------+---------+--------+--------+
  1543.     |     408 x 391, 400 x 400       |  3456   |  4096  |  4864  |
  1544.     +--------------+-----------------+---------+--------+--------+
  1545.                                      |Letter,A4|   B4   |   A3   |
  1546.                                      |  Legal  |        |        |
  1547.                                      +---------+--------+--------+
  1548.                                      |         Paper Size        |
  1549.                                      +---------------------------+
  1550.  
  1551.  
  1552. 4.2.2. Extension fields
  1553.  
  1554. T4Options(292) = (Bit 0 = 0 or 1, Bit 1 = 0, Bit 2 = 0 or 1)        LONG
  1555.     RequiredTIFFExtension (when Compression = 3)
  1556.     T4Options was also known as Group3Options in a prior version of
  1557.     [TIFF].
  1558.     Bit 0 = 1 indicates MR encoding, = 0 indicates MH encoding.
  1559.     Bit 1 must be 0
  1560.     Bit 2 = 1 indicates that EOLs are byte aligned, = 0 EOLs not byte
  1561.     aligned
  1562.     Default is all bits are 0 (applies when MH encoding is used and EOLs
  1563.     are not byte aligned EOLs) (See Section 3.2.2.)
  1564.     The T4Options field is required when the Compression field has a
  1565.     value of 3. This field specifies the encoding used (MH or MR) and
  1566.     whether the EOL codes are byte-aligned or not. If they are byte
  1567.  
  1568.  
  1569.  
  1570. McIntyre, et. al.           Standards Track                    [Page 28]
  1571.  
  1572. RFC 2301              File Format for Internet Fax            March 1998
  1573.  
  1574.  
  1575.     aligned, then fill bits have been added as necessary so that the End
  1576.     of Line (EOL) codes always end on byte boundaries See Sections 3.4,
  1577.     4.5.3 and 4.5.4 for details.
  1578.  
  1579. T6Options(293) = (Bit 0 = 0, Bit 1 = 0). LONG
  1580.     RequiredTIFFExtension (when Compression = 4)
  1581.     Used to indicate parameterization of 2D Modified Modified Read
  1582.     compression. T6Options was also known as Group4Options in a prior
  1583.     version of [TIFF].
  1584.     Bit 0 must be 0.
  1585.     Bit 1 = 0 indicates uncompressed data mode is not allowed; = 1
  1586.     indicates uncompressed data is allowed (see [TIFF]).
  1587.     Default is all bits 0. For FAX, the field must be present and have
  1588.     the value 0. The use of uncompressed data where compression would
  1589.     expand the data size is not allowed for FAX.
  1590.  
  1591.    NOTE: MMR compressed data is two-dimensional and does not use EOLs.
  1592.    Each MMR encoded image MUST include an "end-of-facsimile-block"
  1593.    (EOFB) code at the end of each coded strip; see Section 4.5.6.
  1594.  
  1595. 4.2.3. New fields
  1596.  
  1597.    None.
  1598.  
  1599. 4.3. Recommended TIFF fields
  1600.  
  1601. 4.3.1. Baseline fields
  1602.  
  1603.    See Section 2.2.3.
  1604.  
  1605. 4.3.2. Extension fields
  1606.  
  1607.    See Section 2.2.3.
  1608.  
  1609. 4.3.3. New fields
  1610.  
  1611.    Three new, optional fields, used in the original TIFF-F description
  1612.    to describe page quality, are defined in this specification.  The
  1613.    information contained in these fields is usually obtained from
  1614.    receiving facsimile hardware (if applicable). They SHOULD NOT be used
  1615.    in writing TIFF-F files for facsimile image data that is error
  1616.    corrected or otherwise guaranteed not to have coding errors. Some
  1617.    applications need to understand exactly the error content of the
  1618.    data.  For example, a CAD program might wish to verify that a  file
  1619.    has a low error level before importing it into a high-accuracy
  1620.    document. Because Group 3 facsimile devices do not necessarily
  1621.    perform error correction on the image data, the quality of a received
  1622.    page must be inferred from the pixel count of decoded scan lines. A
  1623.  
  1624.  
  1625.  
  1626. McIntyre, et. al.           Standards Track                    [Page 29]
  1627.  
  1628. RFC 2301              File Format for Internet Fax            March 1998
  1629.  
  1630.  
  1631.    "good" scan line is defined as a line that, when decoded, contains
  1632.    the correct number of pixels. Conversely, a "bad" scan line is
  1633.    defined as a line that, when decoded, comprises an incorrect number
  1634.    of pixels.
  1635.  
  1636. BadFaxLines(326)                                           SHORT or LONG
  1637.     The number of "bad" scan lines encountered by the facsimile device
  1638.     during reception. A "bad" scanline is defined as a scanline that,
  1639.     when decoded, comprises an incorrect number of pixels. Note that
  1640.     PercentBad = (BadFaxLines/ImageLength) * 100
  1641.     No default.
  1642.  
  1643. CleanFaxData(327) = 0, 1, 2.                                       SHORT
  1644.     Indicates if "bad" lines encountered during reception are stored in
  1645.     the data, or if "bad" lines have been replaced by the receiver.
  1646.     0 = No "bad" lines
  1647.     1 = "bad" lines exist, but were regenerated by the receiver,
  1648.     2 = "bad" lines exist, but have not been regenerated.
  1649.     No default.
  1650.  
  1651.    NOTE: Many facsimile devices do not actually output bad lines.
  1652.    Instead, the previous good line is repeated in place of a bad line.
  1653.    Although this substitution, known as line regeneration, results in a
  1654.    visual improvement to the image, the data is nevertheless corrupted.
  1655.    The CleanFaxData field describes the error content of the data.  That
  1656.    is, when the BadFaxLines and ImageLength fields indicate that the
  1657.    facsimile device encountered lines with an incorrect number of pixels
  1658.    during reception, the CleanFaxData field indicates whether these bad
  1659.    lines are actually still in the data or if the receiving facsimile
  1660.    device replaced them with regenerated lines.
  1661.  
  1662. ConsecutiveBadFaxLines(328)                               LONG or SHORT
  1663.     Maximum number of consecutive "bad" scanlines received.  The
  1664.     BadFaxLines field indicates only the quantity of bad lines.
  1665.     No Default.
  1666.  
  1667.    NOTE: The BadFaxLines and ImageLength data indicate only the quantity
  1668.    of bad lines. The ConsecutiveBadFaxLines field is an indicator of the
  1669.    distribution of bad lines and may therefore be a better general
  1670.    indicator of perceived image quality. See Section 4.4.5 for examples
  1671.    of the use of these fields.
  1672.  
  1673. 4.4. Technical Implementation Issues
  1674.  
  1675. 4.4.1   Strips
  1676.  
  1677.    In general, TIFF files divide an image into "strips," also known as
  1678.    "bands."  Each strip contains a few scanlines of the image. By using
  1679.  
  1680.  
  1681.  
  1682. McIntyre, et. al.           Standards Track                    [Page 30]
  1683.  
  1684. RFC 2301              File Format for Internet Fax            March 1998
  1685.  
  1686.  
  1687.    strips, a TIFF reader need not load the entire image into memory,
  1688.    thus enabling it to fetch and decompress small random portions of the
  1689.    image as necessary.
  1690.  
  1691.    The number of scanlines in a strip is described by the RowsPerStrip
  1692.    value and the number of bytes in the strip after compression by the
  1693.    StripByteCount value.  The location in the TIFF file of each strip is
  1694.    given by the StripOffsets values.
  1695.  
  1696.    Strip size is application dependent. The recommended approach for
  1697.    multi- page TIFF-F images is to represent each page as a single
  1698.    strip. Existing TIFF-F usage is typically one strip per page in
  1699.    multi-page TIFF-F files. See Sections 2.1.2 and 2.1.3.
  1700.  
  1701. 4.4.2  Bit Order
  1702.  
  1703.    The current TIFF specification [TIFF] does not require a Baseline
  1704.    TIFF reader to support FillOrder=2, i.e. lowest numbered 1-bit pixel
  1705.    in the least significant bit of a byte. It further recommends that
  1706.    FillOrder=2 be used only in special purpose applications.
  1707.  
  1708.    Facsimile data appears on the phone line in bit-reversed order
  1709.    relative to its description in ITU-T Recommendation T.4.  Therefore,
  1710.    a wide majority of facsimile applications choose this natural order
  1711.    for data in a file. Nevertheless, TIFF-F readers must be able to read
  1712.    data in both bit orders and support FillOrder values of 1 and 2.
  1713.  
  1714. 4.4.3. Multi-Page
  1715.  
  1716.    Many existing applications already read TIFF-F-like files, but do not
  1717.    support the multi-page field.  Since a multi-page format greatly
  1718.    simplifies file management in fax application software, TIFF-F
  1719.    specifies multi-page documents (NewSubfileType = 2) as the standard
  1720.    case.
  1721.  
  1722.    It is recommended that applications export multiple page TIFF-F files
  1723.    without manipulating fields and values.   Historically, some TIFF-F
  1724.    writers have attempted to produce individual single-page TIFF-F files
  1725.    with modified NewSubFileType and PageNumber (page one-of-one) values
  1726.    for export purposes.  However, there is no easy way to link such
  1727.    multiple single page files together into a logical multiple page
  1728.    document, so that this practice is not recommended.
  1729.  
  1730. 4.4.4. Compression
  1731.  
  1732.    In Group 3 facsimile, there are three compression methods which had
  1733.    been standardized as of 1994 and are in common use. The ITU-T T.4
  1734.    Recommendation [T.4] defines a one-dimensional compression method
  1735.  
  1736.  
  1737.  
  1738. McIntyre, et. al.           Standards Track                    [Page 31]
  1739.  
  1740. RFC 2301              File Format for Internet Fax            March 1998
  1741.  
  1742.  
  1743.    known as Modified Huffman (MH) and a two-dimensional method known as
  1744.    Modified READ (MR) (READ is short for Relative Element Address
  1745.    Designate). In 1984, a somewhat more efficient compression method
  1746.    known as Modified Modified READ (MMR) was defined in the ITU-T T.6
  1747.    Recommendation [T.6]. MMR was originally defined for use with Group 4
  1748.    facsimile, so that this compression method has been commonly called
  1749.    Group 4 compression.  In 1991, the MMR method was approved for use in
  1750.    Group 3 facsimile and has since been widely utilized.
  1751.  
  1752.    TIFF-F supports these three compression methods. The most common
  1753.    practice is the one-dimensional Modified Huffman (MH) compression
  1754.    method.  This is specified by setting the Compression field value to
  1755.    3 and then setting bit 0 of the T4Options field to 0.  Alternatively,
  1756.    the two dimensional Modified READ (MR) method, which is much less
  1757.    frequently used in historical TIFF-F implementations, may be selected
  1758.    by setting bit 0 of the T4Options field to 1.  The value of Bit 2 in
  1759.    this field is determined by the use of fill bits.
  1760.  
  1761.    Depending upon the application, the more efficient two-dimensional
  1762.    Modified Modified Read (MMR)compression method from T.6 may be
  1763.    selected by setting the Compression field value to 4 and then setting
  1764.    the first two bits (and all unused bits) of the T6Options field to 0.
  1765.    More information to aid the implementor in making a compression
  1766.    selection is contained in Section 4.5.2.
  1767.  
  1768.    Baseline TIFF also permits use of Compression=2 to specify Modified
  1769.    Huffman compression, but the data does not use EOLs. As a result,
  1770.    TIFF-F uses Compression=3 instead of Compression=2 to specify
  1771.    Modified Huffman compression.
  1772.  
  1773. 4.4.5.  Example Use of Page-quality Fields
  1774.  
  1775.    Here are examples for writing the CleanFaxData, BadFaxLines, and
  1776.    ConsecutiveBadFaxLines fields:
  1777.  
  1778.      1.  Facsimile hardware does not provide page quality
  1779.          information: MUST NOT write page-quality fields.
  1780.      2.  Facsimile hardware provides page quality information, but
  1781.          reports no bad lines.  Write only BadFaxLines = 0.
  1782.      3.  Facsimile hardware provides page quality information, and
  1783.          reports bad lines.  Write both BadFaxLines and
  1784.          ConsecutiveBadFaxLines.  Also write CleanFaxData = 1 or 2 if
  1785.          the hardware's regeneration capability is known.
  1786.      4.  Source image data stream is error-corrected or otherwise
  1787.          guaranteed to be error-free such as for a computer generated
  1788.          file:  SHOULD NOT write page-quality fields.
  1789.  
  1790.  
  1791.  
  1792.  
  1793.  
  1794. McIntyre, et. al.           Standards Track                    [Page 32]
  1795.  
  1796. RFC 2301              File Format for Internet Fax            March 1998
  1797.  
  1798.  
  1799.    TIFF Writers SHOULD only generate these fields when the image has
  1800.    been generated from a fax image data stream where error correction,
  1801.    e.g. Group 3 Error Correction Mode, was not used.
  1802.  
  1803. 4.4.6. Practical Guidelines for Writing and Reading Multi-Page TIFF-F
  1804.    Files
  1805.  
  1806.    Traditionally, historical TIFF-F has required readers and writers to
  1807.    be able to handle multi-page TIFF-F files.  Based on the experience
  1808.    of various TIFF-F implementors, it has been seen that the
  1809.    implementation of TIFF-F can be greatly simplified if certain
  1810.    practical guidelines are followed when writing multi-page TIFF-F
  1811.    files.
  1812.  
  1813.    The structure for a multi-page TIFF-F file will include one IFD per
  1814.    page of the document.  In this case, this IFD will define the
  1815.    attributes for a single page. A second simplifying guideline is that
  1816.    the writer of TIFF-F files SHOULD present IFDs in the same order as
  1817.    the actual sequence of pages.  (The pages are numbered within TIFF-F
  1818.    beginning with page 0 as the first page and then ascending (i.e. 0,
  1819.    1, 2,...). However, any field values over 4 bytes will be stored
  1820.    separately from the IFD. TIFF-F readers SHOULD expect IFDs to be
  1821.    presented in page order, but be able to handle exceptions.
  1822.  
  1823.    Per [TIFF], the exact placement of image data is not specified.
  1824.    However, the strip offsets for each strip of image are defined from
  1825.    within each IFD.   Where possible, another simplifying guideline for
  1826.    the writing of TIFF-F files is to specify that the image data for
  1827.    each page of a multi-page document SHOULD be contained within a
  1828.    single strip (i.e. one image strip per fax page). The use of a single
  1829.    image strip per page is very useful for applications such as store
  1830.    and forward messaging, where the file is usually prepared in advance
  1831.    of the transmission, but other assumptions may apply for the size of
  1832.    the image strip for applications which require the use of "streaming"
  1833.    techniques (see section 4.4.7).  In the event a different image strip
  1834.    size guideline has been used (e.g. constant size for image strips
  1835.    that may be less than the page size), this will immediately be
  1836.    evident from the values/offsets of the fields that are related to
  1837.    strips.
  1838.  
  1839.    A third simplifying guideline is that each IFD SHOULD be placed in
  1840.    the TIFF-F file structure at a point which precedes the image which
  1841.    the IFD describes.
  1842.  
  1843.    In addition, a fourth simplifying guideline for TIFF-F writers and
  1844.    readers is to place the actual image data in a physical order within
  1845.    the TIFF file structure which is consistent with the logical page
  1846.    order.  In practice, TIFF-F readers will need to use the strip
  1847.  
  1848.  
  1849.  
  1850. McIntyre, et. al.           Standards Track                    [Page 33]
  1851.  
  1852. RFC 2301              File Format for Internet Fax            March 1998
  1853.  
  1854.  
  1855.    offsets to find the exact physical location of the image data,
  1856.    whether or not it is presented in logical page order.
  1857.  
  1858.    If the image data is stored in multiple strips, then the strips
  1859.    SHOULD occur in the file in the same order that the data they contain
  1860.    occurs in the facsimile transmission, starting at the top of the
  1861.    page.
  1862.  
  1863.    TIFF-F writers MAY make a fifth simplifying guideline, in which the
  1864.    IFD, the value data and the image data to which the IFD has offsets
  1865.    precede the next image IFD. However, this guideline has been relaxed
  1866.    (writers MAY rather than SHOULD use it) compared to the other
  1867.    guidelines given here to reflect past practices for TIFF-F.
  1868.  
  1869.    In the case of the minimal mode, which is also the minimal subset of
  1870.    Profile S, the SHOULD's and MAY's of these guidelines become SHALL's
  1871.    (see Section 3.5).
  1872.  
  1873.    So, a TIFF-F file which is structured using the guidelines of this
  1874.    section will essentially be composed of a linked list of IFDs,
  1875.    presented in ascending page order, which in turn each point to a
  1876.    single page of image data (one strip per page), where the pages of
  1877.    image data are also placed in a logical page order within the TIFF- F
  1878.    file structure.  (The pages of image data may themselves be stored in
  1879.    a contiguous manner, at the option of the implementor).
  1880.  
  1881. 4.4.7.   Use of TIFF-F for Streaming Applications
  1882.  
  1883.    TIFF-F has historically been used for handling fax image files in
  1884.    applications such as store and forward messaging where the entire
  1885.    size of the file is known in advance.  While TIFF-F may also possibly
  1886.    be used as a file format for cases such as streaming applications,
  1887.    assumptions may be required that differ from those provided in this
  1888.    section (e.g., the entire size and number of pages within the image
  1889.    are not known in advance).  As a result, a definition for the
  1890.    streaming application of TIFF-F is beyond the scope of this document.
  1891.  
  1892. 4.5. Implementation Warnings
  1893.  
  1894. 4.5.1  Uncompressed data
  1895.  
  1896.    TIFF-F requires the ability to read and write at least one-
  1897.    dimensional T.4 Huffman ("compressed") data.  Uncompressed data is
  1898.    not allowed. This means that the "Uncompressed" bit in T4Options or
  1899.    T6Options must be set to 0.
  1900.  
  1901.  
  1902.  
  1903.  
  1904.  
  1905.  
  1906. McIntyre, et. al.           Standards Track                    [Page 34]
  1907.  
  1908. RFC 2301              File Format for Internet Fax            March 1998
  1909.  
  1910.  
  1911. 4.5.2. Encoding and Resolution
  1912.  
  1913.    Since two-dimensional encoding is not required for Group 3
  1914.    compatibility, some historic TIFF-F readers have not been able to
  1915.    read such files.  The minimum subset of TIFF-F REQUIRES support for
  1916.    one dimensional (Modified Huffman) files, so this choice maximizes
  1917.    portability.  However, implementors seeking greater efficiency SHOULD
  1918.    use T.6 MMR compression when writing TIFF-F files.  Some TIFF-F
  1919.    readers will also support two-dimensional Modified READ files.
  1920.    Implementors that wish to have the maximum flexibility in reading
  1921.    TIFF-F files should support all three of these compression methods
  1922.    (MH, MR and MMR).
  1923.  
  1924.    For the case of resolution, almost all facsimile products support
  1925.    both standard (98 dpi) vertical resolution  and "fine" (196 dpi)
  1926.    resolution. Therefore, fine-resolution files are quite portable in
  1927.    the real world.
  1928.  
  1929.    In 1993, the ITU-T added support for higher resolutions in the T.30
  1930.    recommendation including 200 x 200, 300 x 300, 400 x 400 in dots per
  1931.    inch based units.  At the same time, support was added for metric
  1932.    dimensions which are equivalent to the following inch based
  1933.    resolutions: 391v x 204h and 391v x 408h.  Therefore, the full set of
  1934.    inch-based equivalents of the new resolutions are supported in the
  1935.    TIFF-F writer, since they may appear in some image data streams
  1936.    received from Group 3 facsimile devices.  However, many facsimile
  1937.    terminals and older versions of  TIFF-F readers are likely to not
  1938.    support the use of these higher resolutions.
  1939.  
  1940.    Per [T.4], it is permissible for applications to treat the following
  1941.    XResolution values as being equivalent: <204,200> and <400,408>.  In
  1942.    a similar respect, the following YResolution values may also be
  1943.    treated as being equivalent: <98, 100>, <196, 200>, and <391, 400>.
  1944.    These equivalencies were allowed by [T.4] to permit conversions
  1945.    between inch and metric based facsimile terminals.
  1946.  
  1947.    In a similar respect, the optional support of metric based
  1948.    resolutions in the TIFF-F reader (i.e. 77 x 38.5 cm) is included for
  1949.    completeness, since they are used in some legacy TIFF-F applications,
  1950.    but this use is not recommended for the creation of TIFF-F files by a
  1951.    writer.
  1952.  
  1953. 4.5.3. EOL byte-aligned
  1954.  
  1955.    The historical convention for TIFF-F has been that all EOLs in
  1956.    Modified Huffman or Modified READ data must be byte-aligned. However,
  1957.    Baseline TIFF has permitted use of non-byte-aligned EOLs by default,
  1958.    so that a large percentage of TIFF-F reader implementations support
  1959.  
  1960.  
  1961.  
  1962. McIntyre, et. al.           Standards Track                    [Page 35]
  1963.  
  1964. RFC 2301              File Format for Internet Fax            March 1998
  1965.  
  1966.  
  1967.    both conventions. Therefore, the minimum subset of TIFF-F, or Profile
  1968.    S, as defined in Section 3 includes support for both byte-aligned and
  1969.    non- byte-aligned EOLs; see Section 3.2.2.
  1970.  
  1971.    An EOL is said to be byte-aligned when Fill bits have been added as
  1972.    necessary before EOL codes such that EOL always ends on a byte
  1973.    boundary, thus ensuring an  EOL-sequence of a one byte preceded by a
  1974.    zero nibble: xxxx0000 00000001.
  1975.  
  1976.    Modified Huffman encoding encodes bits, not bytes. This means that
  1977.    the end-of-line token may end in the middle of a byte. In byte
  1978.    alignment, extra zero bits (Fill) are added so that the first bit of
  1979.    data following an EOL begins on a byte boundary. In effect, byte
  1980.    alignment relieves application software of the burden of bit-
  1981.    shifting every byte while parsing scan lines for line-oriented image
  1982.    manipulation (such as writing a TIFF file).
  1983.  
  1984.    For Modified READ encoding, each line is terminated by an EOL and a
  1985.    one bit tag bit.  Per [T.4], the value of the tag bit is 0 if the
  1986.    next line contains two dimensional data and 1 if the next line is a
  1987.    reference line.   To maintain byte alignment, fill bits are added
  1988.    before the EOL/tag bit sequence, so that the first bit of data
  1989.    following an MR tag bit begins on a byte boundary.
  1990.  
  1991. 4.5.4. EOL
  1992.  
  1993.    As illustrated in FIGURE 1/T.4 in [T.4], facsimile documents encoded
  1994.    with Modified Huffman begin with an EOL, which in TIFF-F may be byte-
  1995.    aligned. The last line of the image is not terminated by an EOL.  In
  1996.    a similar respect, images encoded with Modified READ two-dimensional
  1997.    encoding begin with an EOL, followed by a tag bit.
  1998.  
  1999. 4.5.5. RTC Exclusion
  2000.  
  2001.    Aside from EOLs, TIFF-F files have historically only contained image
  2002.    data. This means that applications which wish to maintain strict
  2003.    conformance with the rules in [TIFF] and compatibility with
  2004.    historical TIFF-F, SHOULD NOT include the Return To Control sequence
  2005.    (RTC) (consisting of 6 consecutive EOLs) when writing TIFF-F files.
  2006.    However, applications which need to support "transparency" of [T.4]
  2007.    image data MAY include RTCs if the flag settings of the T4Options
  2008.    field are set for non-byte aligned MH or MR image data.  Implementors
  2009.    of TIFF readers should also be aware that there are some existing
  2010.    TIFF-F implementations which include the RTC sequence in MH/MR image
  2011.    data. Therefore, TIFF-F readers MUST be able to process files which
  2012.    do not include RTCs and SHOULD be able to process files which do
  2013.    include RTCs.
  2014.  
  2015.  
  2016.  
  2017.  
  2018. McIntyre, et. al.           Standards Track                    [Page 36]
  2019.  
  2020. RFC 2301              File Format for Internet Fax            March 1998
  2021.  
  2022.  
  2023. 4.5.6 Use of EOFB for T.6 Compressed Images
  2024.  
  2025.    TIFF-F pages which are encoded with the T.6 Modified Modified READ
  2026.    compression method MUST include an "end-of-facsimile-block" (EOFB)
  2027.    code at the end of each coded strip. Per [TIFF], the EOFB code is
  2028.    followed by pad bits as needed to align on a byte boundary. TIFF
  2029.    readers SHOULD ignore any bits other than pad bits beyond the EOFB.
  2030.  
  2031. 4.6. Example Use of TIFF-F
  2032.  
  2033.    The Profile F of TIFF (i.e. TIFF-F content) is a secondary component
  2034.    of the VPIM Message, as defined in [VPIM2].  Voice messaging systems
  2035.    can often handle fax store-and-forward capabilities in addition to
  2036.    tradi- tional voice message store-and-forward functions.  As a
  2037.    result, TIFF-F fax messages can optionally be sent between compliant
  2038.    VPIM systems, and may be rejected if the recipient system cannot deal
  2039.    with fax.
  2040.  
  2041.    Refer to the VPIM Specification for proper usage of this content.
  2042.  
  2043. 4.7. Extended Black-and-white Fax Mode Summary
  2044.  
  2045.    Recommended fields are shown with an asterisk *.
  2046.  
  2047.    Required fields or values are shown with a double asterisk **. If the
  2048.    double asterisk is on the field name, then all the listed values are
  2049.    required of implementations; if the double asterisks are in the
  2050.    Values column, then only the values suffixed with a double asterisk
  2051.    are required of implementations.
  2052.  
  2053.        +---------------------------+--------------------------------+
  2054.        | Baseline Fields           |  Values                        |
  2055.        +---------------------------+--------------------------------+
  2056.        | BitsPerSample             | 1**                            |
  2057.        +---------------------------+--------------------------------+
  2058.        | Compression               | 3**: 1D Modified Huffman and   |
  2059.        |                           |      2D Modified Read coding   |
  2060.        |                           | 4: 2D Modified Modified Read   |
  2061.        |                           |    coding                      |
  2062.        +---------------------------+--------------------------------+
  2063.        | DateTime*                 | {ASCII}: date/time in 24-hour  |
  2064.        |                           | format "YYYY:MM:DD HH:MM:SS"   |
  2065.        +---------------------------+--------------------------------+
  2066.        | FillOrder**               | 1: most significant bit first  |
  2067.        |                           | 2: least significant bit first |
  2068.        +------------------------------------------------------------+
  2069.  
  2070.  
  2071.  
  2072.  
  2073.  
  2074. McIntyre, et. al.           Standards Track                    [Page 37]
  2075.  
  2076. RFC 2301              File Format for Internet Fax            March 1998
  2077.  
  2078.  
  2079.        +------------------------------------------------------------+
  2080.        | ImageDescription*         | {ASCII}: A string describing   |
  2081.        |                           | the contents of the image.     |
  2082.        +---------------------------+--------------------------------+
  2083.        | ImageWidth                | 1728**, 2048, 2432, 2592,      |
  2084.        |                           | 3072, 3456, 3648, 4096, 4864   |
  2085.        +---------------------------+--------------------------------+
  2086.        | ImageLength**             | n: total number of scanlines   |
  2087.        |                           | in image                       |
  2088.        +---------------------------+--------------------------------+
  2089.        | NewSubFileType            | 2**: Bit 1 identifies single   |
  2090.        |                           | page of a multi-page document  |
  2091.        +---------------------------+--------------------------------+
  2092.        | Orientation               | 1**-8, Default 1               |
  2093.        +---------------------------+--------------------------------+
  2094.        | PhotometricInterpretation | 0: pixel value 1 means black   |
  2095.        |  **                       | 1: pixel value 1 means white   |
  2096.        +---------------------------+--------------------------------+
  2097.        | ResolutionUnit**          | 2: inch                        |
  2098.        |                           | 3: centimeter                  |
  2099.        +---------------------------+--------------------------------+
  2100.        | RowsPerStrip**            | n: number of scanlines per     |
  2101.        |                           | TIFF strip                     |
  2102.        +---------------------------+--------------------------------+
  2103.        | SamplesPerPixel           | 1**                            |
  2104.        +---------------------------+--------------------------------+
  2105.        | Software*                 | {ASCII}: name & release        |
  2106.        |                           | number of creator software     |
  2107.        +---------------------------+--------------------------------+
  2108.        | StripByteCounts**         | <n>: number or bytes in TIFF   |
  2109.        |                           | strip                          |
  2110.        +---------------------------+--------------------------------+
  2111.        | StripOffsets**            | <n>: offset from beginning of  |
  2112.        |                           | file to each TIFF strip        |
  2113.        +---------------------------+--------------------------------+
  2114.        | XResolution               | 200, 204**, 300, 400, 408      |
  2115.        |                           | (written in pixels/inch)       |
  2116.        +---------------------------+--------------------------------+
  2117.        | YResolution               | 98**, 196**, 100,              |
  2118.        |                           | 200, 300, 391, 400             |
  2119.        |                           | (written in pixels/inch)       |
  2120.        +---------------------------+--------------------------------+
  2121.        | Extension Fields                                           |
  2122.        +---------------------------+--------------------------------+
  2123.  
  2124.  
  2125.  
  2126.  
  2127.  
  2128.  
  2129.  
  2130. McIntyre, et. al.           Standards Track                    [Page 38]
  2131.  
  2132. RFC 2301              File Format for Internet Fax            March 1998
  2133.  
  2134.  
  2135.        +---------------------------+--------------------------------+
  2136.        | T4Options                 | 0**: required if Compression   |
  2137.        |                           | is Modified Huffman, EOLs are  |
  2138.        |                           | not byte aligned               |
  2139.        |                           | 1: required if Compression is  |
  2140.        |                           | 2D Modified Read, EOLs are     |
  2141.        |                           | not byte aligned               |
  2142.        |                           | 4**: required if Compression   |
  2143.        |                           | is Modified Huffman, EOLs are  |
  2144.        |                           | byte aligned                   |
  2145.        +---------------------------+--------------------------------+
  2146.        | T4Options (continued)     | 5: required if Compression     |
  2147.        |                           | is 2D Modified Read, EOLs are  |
  2148.        |                           | byte aligned                   |
  2149.        +---------------------------+--------------------------------+
  2150.        | T6Options                 | 0: required if Compression is  |
  2151.        |                           | 2D Modified Modified Read      |
  2152.        +---------------------------+--------------------------------+
  2153.        | DocumentName*             | {ASCII}: name of scanned       |
  2154.        |                           | document                       |
  2155.        +---------------------------+--------------------------------+
  2156.        | PageNumber**              | n,m: page number followed by   |
  2157.        |                           | total page count               |
  2158.        +---------------------------+--------------------------------+
  2159.        | New Fields                                                 |
  2160.        +---------------------------+--------------------------------+
  2161.        | BadFaxLines*              | number of "bad" scanlines      |
  2162.        |                           | encountered during reception   |
  2163.        +---------------------------+--------------------------------+
  2164.        | CleanFaxData*             | 0: no "bad" lines              |
  2165.        |                           | 1: "bad" lines exist, but were |
  2166.        |                           | regenerated by receiver        |
  2167.        |                           | 2: "bad" lines exist, but have |
  2168.        |                           | not been regenerated           |
  2169.        +---------------------------+--------------------------------+
  2170.        | ConsecutiveBadFaxLines*   | Max number of consecutive      |
  2171.        |                           | "bad" lines received           |
  2172.        +---------------------------+--------------------------------+
  2173.  
  2174. 5. Lossless JBIG Black-and-White Fax Mode
  2175.  
  2176.    This section defines the lossless JBIG black-and-white mode or
  2177.    Profile J of TIFF for facsimile. Implementations of this profile are
  2178.    required to also implement Profile S.
  2179.  
  2180.  
  2181.  
  2182.  
  2183.  
  2184.  
  2185.  
  2186. McIntyre, et. al.           Standards Track                    [Page 39]
  2187.  
  2188. RFC 2301              File Format for Internet Fax            March 1998
  2189.  
  2190.  
  2191.    The previous section described the extended interchange set of TIFF
  2192.    fields for black-and-white fax, which provided support for the MH, MR
  2193.    and MMR compression of black-and-white images. This section adds a
  2194.    mode with JBIG compression capability.
  2195.  
  2196. 5.1. Overview
  2197.  
  2198.    This section describes a black-and-white mode that uses JBIG
  2199.    compression. The ITU-T has approved the single-progression sequential
  2200.    mode of JBIG [T.82] for Group 3 facsimile. JBIG coding offers
  2201.    improved compression for halftoned originals. JBIG compression is
  2202.    used in accordance with the application rules given in ITU-T Rec.
  2203.    T.85 [T.85].
  2204.  
  2205.    This mode is essentially the extended black-and-white mode with JBIG
  2206.    compression used instead of MH, MR or MMR.
  2207.  
  2208. 5.2. Required TIFF Fields
  2209.  
  2210.    This section lists the required fields and the values they must have
  2211.    to be ITU-compatible. Besides the fields listed in Section 2.2.1, the
  2212.    extended black-and-white fax mode requires the following fields.
  2213.  
  2214. 5.2.1. Baseline fields
  2215.  
  2216.    The TIFF fields that SHALL be used in this mode are the same as those
  2217.    described in Section 4.2.1 for the extended black-and-white mode,
  2218.    with two exceptions: the following text replaces the text in Section
  2219.    4.2.1 for the Compression and FillOrder fields.
  2220.  
  2221. Compression(259) = 9.                                              SHORT
  2222.     RequiredByTIFFBaseline
  2223.     9 = ITU-T Rec. T.82 coding, applying ITU-T Rec. T.85 (JBIG). This is
  2224.     a TIFF extension value.
  2225.     Default = 1 (and is not applicable; field must be specified).
  2226.  
  2227. FillOrder(266) = 2.                                            SHORT
  2228.     RequiredByTIFFBaseline
  2229.     2 = Pixels are arranged within a byte such that pixels with lower
  2230.     column values are stored in the lower-order bits of the bytes, i.e.,
  2231.     least significant bit first (LSB).
  2232.  
  2233.    NOTE: The JBIG coding of black-and-white image data in Profile J
  2234.    follows ITU-T Rec. T.85 [T.85], which specifies LSB first ordering
  2235.    within a byte. Note that Baseline TIFF readers are only required to
  2236.    support MSB first ordering or FillOrder = 1.
  2237.  
  2238. 5.2.2. Extension fields
  2239.  
  2240.  
  2241.  
  2242. McIntyre, et. al.           Standards Track                    [Page 40]
  2243.  
  2244. RFC 2301              File Format for Internet Fax            March 1998
  2245.  
  2246.  
  2247.    Same fields as those in Section 2.2.1.
  2248.  
  2249. 5.2.3. New fields
  2250.  
  2251.    None.
  2252.  
  2253. 5.3. Recommended TIFF Fields
  2254.  
  2255.    See Section 2.2.3 and 2.2.4.
  2256.  
  2257. 5.4.  Lossless JBIG Black-and-white Fax Mode Summary
  2258.  
  2259.    Recommended fields are shown with an asterisk *.
  2260.  
  2261.    Required fields or values are shown with a double asterisk **. If the
  2262.    double asterisk is on the field name, then all the listed values are
  2263.    required of implementations; if the double asterisks are in the
  2264.    Values column, then only the values suffixed with a double asterisk
  2265.    are required of implementations.
  2266.  
  2267.        +---------------------------+--------------------------------+
  2268.        | Baseline Fields           |  Values                        |
  2269.        +---------------------------+--------------------------------+
  2270.        | BitsPerSample             | 1**                            |
  2271.        +---------------------------+--------------------------------+
  2272.        | Compression               | 9**: JBIG coding               |
  2273.        +---------------------------+--------------------------------+
  2274.        | DateTime*                 | {ASCII}: date/time in 24-hour  |
  2275.        |                           | format "YYYY:MM:DD HH:MM:SS"   |
  2276.        +---------------------------+--------------------------------+
  2277.        | FillOrder**               | 1: most significant bit first  |
  2278.        |                           | 2: least significant bit first |
  2279.        +---------------------------+--------------------------------+
  2280.        | ImageDescription*         | {ASCII}: A string describing   |
  2281.        |                           | the contents of the image.     |
  2282.        +---------------------------+--------------------------------+
  2283.        | ImageWidth                | 1728**, 2048, 2432, 2592,      |
  2284.        |                           | 3072, 3456, 3648, 4096, 4864   |
  2285.        +---------------------------+--------------------------------+
  2286.        | ImageLength**             | n: total number of scanlines   |
  2287.        |                           | in image                       |
  2288.        +---------------------------+--------------------------------+
  2289.        | NewSubFileType**          | 2: Bit 1 identifies single     |
  2290.        |                           | page of a multi-page document  |
  2291.        +---------------------------+--------------------------------+
  2292.        | Orientation               | 1**-8, Default 1               |
  2293.        +------------------------------------------------------------+
  2294.  
  2295.  
  2296.  
  2297.  
  2298. McIntyre, et. al.           Standards Track                    [Page 41]
  2299.  
  2300. RFC 2301              File Format for Internet Fax            March 1998
  2301.  
  2302.  
  2303.        +---------------------------+--------------------------------+
  2304.        | PhotometricInterpretation | 0: pixel value 1 means black   |
  2305.        |  **                       | 1: pixel value 1 means white   |
  2306.        +---------------------------+--------------------------------+
  2307.        | ResolutionUnit**          | 2: inch                        |
  2308.        |                           | 3: centimeter                  |
  2309.        +---------------------------+--------------------------------+
  2310.        | RowsPerStrip**            | n: number of scanlines per     |
  2311.        |                           | TIFF strip                     |
  2312.        +---------------------------+--------------------------------+
  2313.        | SamplesPerPixel**         | 1                              |
  2314.        +---------------------------+--------------------------------+
  2315.        | Software*                 | {ASCII}: name & release        |
  2316.        |                           | number of creator software     |
  2317.        +---------------------------+--------------------------------+
  2318.        | StripByteCounts**         | <n>: number of bytes in TIFF   |
  2319.        |                           | strip                          |
  2320.        +---------------------------+--------------------------------+
  2321.        | StripOffsets**            | <n>: offset from beginning of  |
  2322.        |                           | file to each TIFF strip        |
  2323.        +---------------------------+--------------------------------+
  2324.        | XResolution               | 200, 204**, 300, 400, 408      |
  2325.        |                           | (written in pixels/inch)       |
  2326.        +---------------------------+--------------------------------+
  2327.        | YResolution               | 98**, 196**, 100,              |
  2328.        |                           | 200, 300, 391, 400             |
  2329.        |                           | (written in pixels/inch)       |
  2330.        +---------------------------+--------------------------------+
  2331.        | Extension Fields                                           |
  2332.        +---------------------------+--------------------------------+
  2333.        | DocumentName*             | {ASCII}: name of document      |
  2334.        |                           |  scanned                       |
  2335.        +---------------------------+--------------------------------+
  2336.        | PageNumber**              | n,m: page number followed by   |
  2337.        |                           | total page count               |
  2338.        +---------------------------+--------------------------------+
  2339.        | New Fields                                                 |
  2340.        +---------------------------+--------------------------------+
  2341.        | GlobalParametersIFD*      | IFD: global parameters IFD     |
  2342.        +---------------------------+--------------------------------+
  2343.        | ProfileType*              | n: type of data stored in file |
  2344.        +---------------------------+--------------------------------+
  2345.        | FaxProfile*               | n: ITU-compatible fax mode     |
  2346.        +---------------------------+--------------------------------+
  2347.        | CodingMethods*            | n: compression algorithms used |
  2348.        |                           | in file                        |
  2349.        +---------------------------+--------------------------------+
  2350.  
  2351.  
  2352.  
  2353.  
  2354. McIntyre, et. al.           Standards Track                    [Page 42]
  2355.  
  2356. RFC 2301              File Format for Internet Fax            March 1998
  2357.  
  2358.  
  2359. 6. Base Color Fax Mode
  2360.  
  2361. 6.1. Overview
  2362.  
  2363.    This section defines the lossy color mode or Profile C of TIFF for
  2364.    facsimile. Implementations of this profile are required to also
  2365.    implement Profile S.
  2366.  
  2367.    This is the base mode for color and grayscale facsimile, which means
  2368.    that all applications that support color fax must support this mode.
  2369.    The basic approach is the lossy JPEG compression [T.4, Annex E; T.81]
  2370.    of L*a*b* color data [T.42]. Grayscale applications use the L*
  2371.    lightness component; color applications use the L*, a* and b*
  2372.    components.
  2373.  
  2374.    This mode uses a new PhotometricInterpretation field value to
  2375.    describe the L*a*b* encoding specified in [T.42]. This encoding
  2376.    differs in two ways from the other L*a*b* encodings used in TIFF
  2377.    [TIFF, TTN1]: it specifies a different default range for the a* and
  2378.    b* components, based on a comprehensive evaluation of existing
  2379.    hardcopy output, and it optionally allows selectable range for the
  2380.    L*, a* and b* components.
  2381.  
  2382. 6.2. Required TIFF Fields
  2383.  
  2384.    This section lists the required fields, in addition to those given in
  2385.    Section 2.2.1, and the values they must support to be compatible with
  2386.    ITU-T Rec. T.42 and Annex E in ITU-T Rec. T.4.
  2387.  
  2388. 6.2.1. Baseline Fields
  2389.  
  2390. ImageWidth(256).                                           SHORT or LONG
  2391.     This mode supports the following fixed page widths: 864, 1024, 1216,
  2392.     1728, 2048, 2432, 2592, 3072, 3456, 3648, 4096, 4864.
  2393.  
  2394. NewSubFileType(254) = (Bit 1=1).                                    LONG
  2395.     RequiredByTIFFforFAX
  2396.     Bit 1 is 1 if the image is a single page of a multi-page document.
  2397.     Default = 0 (no subfile bits on, so may not be omitted for fax)
  2398.  
  2399. BitsPerSample(258) = 8, 12.                                        SHORT
  2400.     Count = SamplesPerPixel
  2401.     The base color fax mode requires 8 bits per sample, with 12 as an
  2402.     option. 12 bits per sample is not baseline TIFF.
  2403.  
  2404. Compression(259) = 7.                                              SHORT
  2405.     Base color fax mode uses Baseline JPEG compression. Value 7
  2406.     represents JPEG compression as specified in [TTN2].
  2407.  
  2408.  
  2409.  
  2410. McIntyre, et. al.           Standards Track                    [Page 43]
  2411.  
  2412. RFC 2301              File Format for Internet Fax            March 1998
  2413.  
  2414.  
  2415. FillOrder(266) = 1 , 2.                                            SHORT
  2416.     RequiredByTIFFBaseline
  2417.     Profile C readers must be able to read data in both bit orders,
  2418.     but the vast majority of facsimile products store data LSB
  2419.     first, exactly as it appears on the telephone line.
  2420.               1 = Most Significant Bit first.
  2421.               2 = Least Significant Bit first
  2422.  
  2423. PhotometricInterpretation(262) = 10.                               SHORT
  2424.     Base color fax mode requires pixel values to be stored using the CIE
  2425.     L*a*b* encoding defined in ITU-T Rec. T.42. This encoding is
  2426.     indicated by the PhotometricInterpretation value 10, referred to as
  2427.     ITULAB. With this encoding, the minimum sample value is  mapped to 0
  2428.     and the maximum sample value is mapped to (2^n - 1), i.e. the
  2429.     maximum value, where n is the BitsPerSample value. The conversion
  2430.     from unsigned ITULAB-encoded samples values to signed CIE L*a*b*
  2431.     values is determined by the Decode field; see Sec. 6.2.3
  2432.  
  2433.    NOTE: PhotometricInterpretation values 8 and 9 specify encodings for
  2434.    use with 8-bit-per-sample CIE L*a*b* [TIFF] and ICC L*a*b* [TTN1]
  2435.    data, but they are fixed encodings, which use different minimum and
  2436.    maximum samples than the T.42 default encoding. As currently defined,
  2437.    they are not able to represent fax-encoded L*a*b* data.
  2438.  
  2439. ResolutionUnit(296) = 2, 3.                                        SHORT
  2440.     The unit of measure for resolution. 2 = inch, 3 = centimeter;
  2441.     Default = 2 (field may be omitted if this is the value)
  2442.  
  2443. SamplesPerPixel(277) = 1, 3.                                       SHORT
  2444.     1: L* component only, required in base color mode
  2445.     3: L*, a*, b* components
  2446.     Encoded according to PhotometricInterpretation field
  2447.  
  2448. XResolution(282) = 100, 200, 300, 400.                          RATIONAL
  2449. YResolution(283) = 100, 200, 300, 400.                          RATIONAL
  2450.     The resolution of the image is expressed in pixels per resolution
  2451.     unit. In pixels per inch, allowed XResolution values are: 100, 200,
  2452.     300, and 400. The base color fax mode requires the pixels to be
  2453.     square, hence YResolution must equal XResolution. Base resolution is
  2454.     200 pixels per inch and SHALL be supported by all implementations of
  2455.     this mode. See Section 2.2.2 for inch-metric equivalency.
  2456.  
  2457. NOTE: Not all combinations of XResolution, YResolution and ImageWidth
  2458. are legal. The following table gives the legal combinations for inch-
  2459. based resolutions and the corresponding paper sizes [T.30].
  2460.  
  2461.  
  2462.  
  2463.  
  2464.  
  2465.  
  2466. McIntyre, et. al.           Standards Track                    [Page 44]
  2467.  
  2468. RFC 2301              File Format for Internet Fax            March 1998
  2469.  
  2470.  
  2471.     +--------------------------------+---------------------------+
  2472.     |   XResolution x YResolution    |         ImageWidth        |
  2473.     +--------------------------------+---------------------------+
  2474.     |           100 x 100            |   864   |  1024  |  1216  |
  2475.     +--------------------------------+---------------------------+
  2476.     |           200 x 200            |  1728   |  2048  |  2432  |
  2477.     +--------------------------------+---------------------------+
  2478.     |           300 x 300            |  2592   |  3072  |  3648  |
  2479.     +--------------------------------+---------------------------+
  2480.     |           400 x 400            |  3456   |  4096  |  4864  |
  2481.     +--------------------------------+---------------------------+
  2482.                                      |Letter,A4|   B4   |   A3   |
  2483.                                      |  Legal  |        |        |
  2484.                                      +---------------------------+
  2485.                                      |         Paper Size        |
  2486.                                      +---------------------------+
  2487.  
  2488. 6.2.2 Extension Fields
  2489.  
  2490. The JPEG compression standard allows for the a*b* chroma components of
  2491. an image to be subsampled relative to the L* lightness component. The
  2492. extension fields ChromaSubSampling and ChromaPositioning define the
  2493. subsampling. They are the same as YCbCrSubSampling and YCbCrPositioning
  2494. in [TIFF], but have been renamed to reflect their applicability to other
  2495. color spaces.
  2496.  
  2497. ChromaSubSampling(530).                                            SHORT
  2498.     Count = 2
  2499.     Specifies the subsampling factors for the chroma components of a
  2500.     L*a*b* image. The two subfields of this field, ChromaSubsampleHoriz
  2501.     and ChromaSubsampleVert, specify the horizontal and vertical
  2502.     subsampling factors respectively.
  2503.  
  2504.     SHORT 0: ChromaSubsampleHoriz = 1, 2.
  2505.     1: equal numbers of lightness and chroma samples horizontally,
  2506.     2: twice as many lightness samples as chroma samples horizontally,
  2507.  
  2508.     SHORT 1: ChromaSubsampleVert = 1, 2.
  2509.     1: equal numbers of lightness and chroma samples vertically,
  2510.     2: twice as many lightness samples as chroma samples vertically,
  2511.  
  2512.     The default value for ChromaSubSampling is (2,2), which is the
  2513.     default for chroma subsampling in color fax [T.4, Annex E]. No
  2514.     chroma subsampling, i.e. ChromaSubSampling = (1,1), is an option
  2515.     for color fax
  2516.  
  2517. ChromaPositioning(531) = 1.                                        SHORT
  2518.     Specifies the spatial positioning of chroma components relative to
  2519.  
  2520.  
  2521.  
  2522. McIntyre, et. al.           Standards Track                    [Page 45]
  2523.  
  2524. RFC 2301              File Format for Internet Fax            March 1998
  2525.  
  2526.  
  2527.     the lightness component.
  2528.     1: centered,
  2529.     A value of 1 means chrominance samples are spatially offset and
  2530.     centered with respect to luminance samples. See the current TIFF
  2531.     specification under YcbCr positioning for further information.
  2532.     Default = 1, which is what ITU-T T.4, Annex E specifies.
  2533.  
  2534. 6.2.3. New Fields
  2535.  
  2536. Decode(433).                                                   SRATIONAL
  2537.     Count = 2 * SamplesPerPixel
  2538.     Describes how to map image sample values into the range of values
  2539.     appropriate for the current color space. In general, the values are
  2540.     taken in pairs and specify the minimum and maximum output value for
  2541.     each color component. For the base color fax mode, Decode has a
  2542.     count of 6 values and maps the unsigned ITULAB-encoded sample values
  2543.     (Lsample, asample, bsample) to signed L*a*b* values, as follows:.
  2544.  
  2545.         L* = Decode[0] + Lsample x (Decode[1]-Decode[0])/(2^n -1)
  2546.         a* = Decode[2] + asample x (Decode[3]-Decode[2])/(2^n -1)
  2547.         b* = Decode[4] + bsample x (Decode[5]-Decode[4])/(2^n -1)
  2548.  
  2549.     where Decode[0], Decode[2] and Decode[4] are the minimum values for
  2550.     L*, a* and b*; Decode[1], Decode[3] and Decode[5] are the maximum
  2551.     values for L*, a* and b*; and n is the BitsPerSample, either 8 or
  2552.     12. For example, when n=8, L*=Decode[0] when Lsample=0 and
  2553.     L*=Decode[1] when Lsample=255.
  2554.  
  2555.     ITU-T Rec. T.42 specifies the ITULAB encoding in terms of a range
  2556.     and offset for each component, which are related to the minimum and
  2557.     maximum values as follows:
  2558.  
  2559.         minimum = - (range x offset) / 2^n - 1
  2560.         maximum = minimum + range
  2561.  
  2562.     The Decode field default values depend on the color space. For the
  2563.     ITULAB color space encoding, the default values correspond to the
  2564.     base range and offset, as specified in ITU-T Rec. T.42 [T.42]. The
  2565.     following table gives the base range and offset values for
  2566.     BitsPerSample=8 and 12, and the corresponding default minimum and
  2567.     maximum default values for the Decode field, calculated using the
  2568.     equations above when PhotometricInterpetation=10.
  2569.  
  2570.  
  2571.  
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  
  2577.  
  2578. McIntyre, et. al.           Standards Track                    [Page 46]
  2579.  
  2580. RFC 2301              File Format for Internet Fax            March 1998
  2581.  
  2582.  
  2583.                        +-----------------------------------------------+
  2584.                        | ITU-T Rec. T.42  |           Decode           |
  2585.  +---------+-----------|   base values    |       default values       |
  2586.  | BitsPer + Component +------------------+----------------------------+
  2587.  | -Sample |           |  Range | Offset  |      Min     |     Max     |
  2588.  +---------+-----------+--------+---------+--------------+-------------+
  2589.  |    8    |    L*     |   100  |    0    |       0      |     100     |
  2590.  |         +-----------+--------+---------+--------------+-------------+
  2591.  |         |    a*     |   170  |   128   |  -21760/255  |  21590/255  |
  2592.  |         +-----------+--------+---------+--------------+-------------+
  2593.  |         |    b*     |   200  |    96   |  -19200/255  |  31800/255  |
  2594.  +---------+-----------+--------+---------+--------------+-------------+
  2595.  |   12    |    L*     |   100  |    0    |       0      |     100     |
  2596.  |         +-----------+--------+---------+--------------+-------------+
  2597.  |         |    a*     |   170  |  2048   | -348160/4095 | 347990/4095 |
  2598.  |         +-----------+--------+---------+--------------+-------------+
  2599.  |         |    b*     |   200  |  1536   | -307200/4095 | 511800/4095 |
  2600.  +---------+-----------+--------+---------+--------------+-------------+
  2601.  
  2602.    For example, when PhotometricInterpretation=10 and BitsPerSample=8,
  2603.    the default value for Decode is (0, 100, -21760/255, 21590/255,
  2604.    -19200/255, 31800/255).
  2605.  
  2606. 6.3. Recommended TIFF Fields
  2607.  
  2608.    See Sections 2.2.3. and 2.2.4.
  2609.  
  2610. 6.4 Base Color Fax Mode Summary
  2611.  
  2612.    Recommended fields are shown with an asterisk *
  2613.  
  2614.    Required fields or values are shown with a double asterisk **. If the
  2615.    double asterisk is on the field name, then all the listed values are
  2616.    required of implementations; if the double asterisks are in the
  2617.    Values column, then only the values suffixed with a double asterisk
  2618.    are required of implementations.
  2619.  
  2620.        +---------------------------+--------------------------------+
  2621.        | Baseline Fields           | Values                         |
  2622.        +---------------------------+--------------------------------+
  2623.        | BitsPerSample             | 8**: 8 bits per color sample   |
  2624.        |                           | 12: optional 12 bits/sample    |
  2625.        +---------------------------+--------------------------------+
  2626.        | Compression**             | 7: JPEG                        |
  2627.        +---------------------------+--------------------------------+
  2628.        | DateTime*                 | {ASCII}: date/time in 24-hour  |
  2629.        |                           | format "YYYY:MM:DD HH:MM:SS"   |
  2630.        +---------------------------+--------------------------------+
  2631.  
  2632.  
  2633.  
  2634. McIntyre, et. al.           Standards Track                    [Page 47]
  2635.  
  2636. RFC 2301              File Format for Internet Fax            March 1998
  2637.  
  2638.  
  2639.        +------------------------------------------------------------+
  2640.        | FillOrder**               | 1: most significant bit first  |
  2641.        |                           | 2: least significant bit first |
  2642.        +---------------------------+--------------------------------+
  2643.        | ImageDescription*         | {ASCII}: A string describing   |
  2644.        |                           | the contents of the image.     |
  2645.        +---------------------------+--------------------------------+
  2646.        | ImageWidth                | 864, 1024, 1216, 1728**, 2048  |
  2647.        |                           | 2432, 2592, 3072, 3456, 3648   |
  2648.        |                           | 4096, 4864                     |
  2649.        +---------------------------+--------------------------------+
  2650.        | ImageLength**             | n: total number of scanlines   |
  2651.        |                           | in image                       |
  2652.        +---------------------------+--------------------------------+
  2653.        | NewSubFileType**          | 2: Bit 1 identifies single page|
  2654.        |                           | of a multi-page document       |
  2655.        +---------------------------+--------------------------------+
  2656.        | Orientation               | 1**-8, Default 1               |
  2657.        +---------------------------+--------------------------------+
  2658.        | PhotometricInterpretation | 10**: ITULAB                   |
  2659.        +---------------------------+--------------------------------+
  2660.        | ResolutionUnit**          | 2: inch                        |
  2661.        |                           | 3: centimeter                  |
  2662.        +---------------------------+--------------------------------+
  2663.        | RowsPerStrip**            | n: number of scanlines per     |
  2664.        |                           | TIFF strip                     |
  2665.        +---------------------------+--------------------------------+
  2666.        | SamplesPerPixel           | 1**: L* (lightness)            |
  2667.        |                           | 3: LAB                         |
  2668.        +---------------------------+--------------------------------+
  2669.        | Software*                 | {ASCII}: name & release number |
  2670.        |                           | of creator software            |
  2671.        +---------------------------+--------------------------------+
  2672.        | StripByteCounts**         | <n>: number or bytes in        |
  2673.        |                           | TIFF strip                     |
  2674.        +---------------------------+--------------------------------+
  2675.        | StripOffsets**            | <n>: offset from beginning     |
  2676.        |                           | of file to each TIFF strip     |
  2677.        +---------------------------+--------------------------------+
  2678.        | XResolution               | 100, 200**, 300, 400 (written  |
  2679.        |                           | in pixels/inch)                |
  2680.        +---------------------------+--------------------------------+
  2681.        | YResolution               | 100, 200**, 300, 400           |
  2682.        |                           | (must equal XResolution)       |
  2683.        +---------------------------+--------------------------------+
  2684.  
  2685.  
  2686.  
  2687.  
  2688.  
  2689.  
  2690. McIntyre, et. al.           Standards Track                    [Page 48]
  2691.  
  2692. RFC 2301              File Format for Internet Fax            March 1998
  2693.  
  2694.  
  2695.        +---------------------------+--------------------------------+
  2696.        | Extension Fields                                           |
  2697.        +---------------------------+--------------------------------+
  2698.        | DocumentName*             | {ASCII}: name of scanned       |
  2699.        |                           | document                       |
  2700.        +---------------------------+--------------------------------+
  2701.        | PageNumber**              | n,m: page number followed by   |
  2702.        |                           | total page count               |
  2703.        +---------------------------+--------------------------------+
  2704.        | ChromaSubSampling         | (1,1), (2, 2)**                |
  2705.        |                           | (1, 1): equal numbers of       |
  2706.        |                           | lightness and chroma samples   |
  2707.        |                           | horizontally and vertically    |
  2708.        |                           | (2, 2): twice as many lightness|
  2709.        |                           | samples as chroma samples      |
  2710.        |                           | horizontally and vertically    |
  2711.        +---------------------------+--------------------------------+
  2712.        | ChromaPositioning         | 1**: centered                  |
  2713.        +---------------------------+--------------------------------+
  2714.        | New Fields                                                 |
  2715.        +---------------------------+--------------------------------+
  2716.        | Decode**                  | minL, maxL, mina, maxa, minb,  |
  2717.        |                           | maxb: minimum and maximum      |
  2718.        |                           | values for L*a*b*              |
  2719.        +---------------------------+--------------------------------+
  2720.        | GlobalParametersIFD*      | IFD: IFD containing            |
  2721.        |                           | global parameters              |
  2722.        +---------------------------+--------------------------------+
  2723.        | ProfileType*              | n: type of data stored in      |
  2724.        |                           | TIFF file                      |
  2725.        +---------------------------+--------------------------------+
  2726.        | FaxProfile*               | n: ITU-compatible fax mode     |
  2727.        +---------------------------+--------------------------------+
  2728.        | CodingMethods*            | n: compression algorithms      |
  2729.        |                           | used in file                   |
  2730.        +---------------------------+--------------------------------+
  2731.        | VersionYear*              | byte sequence: year of ITU std |
  2732.        +---------------------------+--------------------------------+
  2733.  
  2734. 7. Lossless Color Mode
  2735.  
  2736.    This section defines the lossless color mode or Profile L of TIFF for
  2737.    facsimile. Implementations of this profile are required to also
  2738.    implement Profiles S and C.
  2739.  
  2740.  
  2741.  
  2742.  
  2743.  
  2744.  
  2745.  
  2746. McIntyre, et. al.           Standards Track                    [Page 49]
  2747.  
  2748. RFC 2301              File Format for Internet Fax            March 1998
  2749.  
  2750.  
  2751. 7.1. Overview
  2752.  
  2753.    This mode, defined in [T.43], uses JBIG to losslessly code three
  2754.    types of color and grayscale images: one bit per color CMY, CMYK and
  2755.    RGB images; a palettized (i.e. mapped) color image; and continuous
  2756.    tone color and grayscale images. The last two are multi-level and use
  2757.    the L*a*b* encoding specified in [T.42].
  2758.  
  2759. 7.1.1. Color Encoding
  2760.  
  2761.    While under development, this mode was called T.Palette, as one of
  2762.    its major additions was palette or mapped color images. Baseline TIFF
  2763.    only allows RGB color maps, but ITU-T Rec. T.43 requires L*a*b* color
  2764.    maps, using the encoding specified in ITU-T Rec. T.42. Palette color
  2765.    images are expressed with indices (bits per sample) of 12 bits or
  2766.    less, or optionally 13 to 16 bits, per [T.43].
  2767.  
  2768.    Enabling T.43 color maps in TIFF requires the extension field
  2769.    Indexed, defined in [TTN1], and the PhotometricInterpretation field
  2770.    value 10, defined in Section 6.2.1. The following table shows the
  2771.    corresponding PhotometricInterpretation, SamplesPerPixel,
  2772.    BitsPerSample and Indexed field values for the different T.43 image
  2773.    types.
  2774.  
  2775.        +----------------------------------------------------------+
  2776.        | Image Type |PhotometricIn| Samples  | Bits Per | Indexed |
  2777.        |            |-terpretation| PerPixel |  Sample  |         |
  2778.        |------------+-------------+----------+----------+---------|
  2779.        |     RGB    |    2=RGB    |     3    |    1     |    0    |
  2780.        +----------------------------------------------------------+
  2781.        |     CMY    |    5=CMYK   |     3    |    1     |    0    |
  2782.        +------------+-------------+----------+----------+---------+
  2783.        |     CMYK   |    5=CMYK   |     4    |    1     |    0    |
  2784.        +------------+-------------+----------+----------+---------+
  2785.        |   Palette  |  10=ITULAB  |     1    |    n     |    1    |
  2786.        +------------+-------------+----------+----------+---------+
  2787.        |  Grayscale |  10=ITULAB  |     1    |   8, 12  |    0    |
  2788.        +------------+-------------+----------+----------+---------+
  2789.        |    Color   |  10=ITULAB  |     3    |   8, 12  |    0    |
  2790.        +------------+-------------+----------+----------+---------+
  2791.  
  2792. 7.1.2. JBIG Encoding
  2793.  
  2794.    T.43 uses the single-progression sequential mode of JBIG, defined in
  2795.    ITU-T Rec. T.82. To code multi-level images using JBIG, which is a
  2796.    bi-level compression method, an image is resolved into a set of bit-
  2797.    planes, and each bit-plane is then JBIG compressed. For continuous
  2798.    tone color and grayscale images, Gray code conversion is used. The
  2799.  
  2800.  
  2801.  
  2802. McIntyre, et. al.           Standards Track                    [Page 50]
  2803.  
  2804. RFC 2301              File Format for Internet Fax            March 1998
  2805.  
  2806.  
  2807.    Gray code conversion is part of the data stream encoding, and is
  2808.    therefore invisible to TIFF.
  2809.  
  2810. 7.2. Required TIFF Fields
  2811.  
  2812.    This section lists the required fields, in addition to those in
  2813.    Section 2.2.1, and the values they must have to be compatible with
  2814.    ITU-T Rec. T.43.
  2815.  
  2816. 7.2.1. Baseline Fields
  2817.  
  2818. ImageWidth(256).                                           SHORT or LONG
  2819.     Same page widths as the base color mode; see Section 6.2.1.
  2820.  
  2821. NewSubFileType(254) = (Bit 1=1).                                    LONG
  2822.     RequiredByTIFFforFAX
  2823.     Bit 1 is 1 if the image is a single page of a multi-page document.
  2824.     Default = 0 (no subfile bits on, so may not be omitted for fax)
  2825.  
  2826. BitsPerSample(258) = 1, 2-8, 9-16.                                 SHORT
  2827.     Count = SamplesPerPixel
  2828.     RGB, CMY, CMYK: 1 bit per sample
  2829.     Continuous tone (L*a*b*): 2-8 bits per sample, 9-12 bits optional
  2830.     Palette color: 12 or fewer bits per sample, 13-16 bits optional
  2831.     Note: More than 8 bits per sample is not baseline TIFF.
  2832.  
  2833. ColorMap(320).                                                     SHORT
  2834.     Count = 3 * number of sample values
  2835.     Lossless color fax mode supports palette-color (indexed) images
  2836.     where the single component value is used as an index into a full
  2837.     color lookup table stored in the ColorMap field. The sample value is
  2838.     encoded using the number of bits given by the BitsPerSample field
  2839.     value. However, per [T.43],the number of sample values may be less
  2840.     than 2**BitsPerSample. The color lookup table is only required to
  2841.     have as many entries as there are number of sample values. For
  2842.     palette-color images in lossless color fax mode, the ITULAB encoding
  2843.     with 8 or optionally 12 bits per color map value is supported. To
  2844.     utilize a color map, the TIFF Indexed field must be present. TIFF
  2845.     orders the color map values so that all the L* values come first,
  2846.     followed by all the a* values and then all the b* values. Because
  2847.     ITU-T Rec. T.43 specifies a "chunky" ordering with the L*a*b*
  2848.     components of the first value, followed by those of the second
  2849.     value, and so on, reproducing color map values from a fax data
  2850.     stream in a TIFF file requires reordering values.
  2851.  
  2852. Compression(259) = 10.                                             SHORT
  2853. 10: ITU-T Rec. T.43 representation, using ITU-T Rec. T.82 (JBIG)
  2854.     coding
  2855.  
  2856.  
  2857.  
  2858. McIntyre, et. al.           Standards Track                    [Page 51]
  2859.  
  2860. RFC 2301              File Format for Internet Fax            March 1998
  2861.  
  2862.  
  2863. FillOrder(266) = 1 , 2.                                            SHORT
  2864.     RequiredByTIFFBaseline
  2865.     Profile F readers must be able to read data in both bit orders,
  2866.     but the vast majority of facsimile products store data LSB
  2867.     first, exactly as it appears on the telephone line.
  2868.               1 = Most Significant Bit first.
  2869.               2 = Least Significant Bit first
  2870.  
  2871. PhotometricInterpretation(262) = 2, 5, 10.                         SHORT
  2872.     2: RGB
  2873.     5: CMYK, including CMY
  2874.     10: ITULAB
  2875.     Image data may also be stored as palette color images, where pixel
  2876.     values are represented by a single component that is an index into a
  2877.     color map using the ITULAB encoding. This color map is specified by
  2878.     the ColorMap field. To use palette color images, set the
  2879.     PhotometricInterpretation to 10,SamplesPerPixel to 1, and Indexed to
  2880.     1. The color map is stored in the ColorMap field. See Section 7.1.1
  2881.     for further discussion on the color encoding.
  2882.  
  2883. ResolutionUnit(296) = 2, 3.                                        SHORT
  2884.     The unit of measure for resolution. 2 = inch, 3 = centimeter;
  2885.     Default = 2 (field may be omitted if this is the value)
  2886.  
  2887. SamplesPerPixel(277) = 1, 3, 4.                                    SHORT
  2888.     1: Palette color image, or L*-only if Indexed = 0 and
  2889.        PhotometricInterpretation is 10 (ITULAB).
  2890.     3: RGB, or L*a*b*, or CMY if PhotometricInterpretation is 5 (CMYK).
  2891.     4: CMYK.
  2892.  
  2893. XResolution(282) = 100, 200, 300, 400.                          RATIONAL
  2894. YResolution(283) = 100, 200, 300, 400.                          RATIONAL
  2895.     The resolution of the image is expressed in pixels per resolution
  2896.     unit. In pixels per inch, allowed XResolution values are: 100, 200,
  2897.     300, and 400. The lossless color fax mode requires the pixels to be
  2898.     square, hence YResolution must equal XResolution. Base resolution is
  2899.     200 pixels per inch. See Section 2.2.2 for inch-metric equivalency.
  2900.  
  2901. 7.2.2. Extension Fields
  2902.  
  2903. Indexed(364) = 0, 1.                                               SHORT
  2904.     0: not a palette-color image
  2905.     1: palette-color image
  2906.     This field is used to indicate that each sample value is an index
  2907.     into an array of color values specified in the ColorMap field.
  2908.     Lossless color fax mode supports palette-color images with the
  2909.     ITULAB encoding. The SamplesPerPixel value must be 1.
  2910.  
  2911.  
  2912.  
  2913.  
  2914. McIntyre, et. al.           Standards Track                    [Page 52]
  2915.  
  2916. RFC 2301              File Format for Internet Fax            March 1998
  2917.  
  2918.  
  2919. 7.2.3. New Fields
  2920.  
  2921. Decode(433)                                                    SRATIONAL
  2922.     Decode is used in connection with the ITULAB encoding of image data
  2923.     and color map values; see Section 6.2.3.
  2924.  
  2925. 7.3. Recommended TIFF Fields
  2926.  
  2927.    See Sections 2.2.3. and 2.2.4.
  2928.  
  2929. 7.4. Lossless Color Fax Mode Summary
  2930.  
  2931.    Recommended fields are shown with an asterisk *.
  2932.  
  2933.         +--------------------+--------------------------------------+
  2934.         |   Baseline Fields  |             Values                   |
  2935.         +--------------------+--------------------------------------+
  2936.         | BitsPerSample      | 1: Binary RGB, CMY(K)                |
  2937.         |                    | 8: 8 bits per color sample           |
  2938.         |                    | 9-16: optional                       |
  2939.         +--------------------+--------------------------------------+
  2940.         | ColorMap           | n: LAB color map                     |
  2941.         +--------------------+--------------------------------------+
  2942.         | Compression        | 10: JBIG, per T.43                   |
  2943.         +--------------------+--------------------------------------+
  2944.         | DateTime*          | {ASCII}:  date/time in the 24-hour   |
  2945.         |                    | format "YYYY:MM:DD HH:MM:SS"         |
  2946.         +--------------------+--------------------------------------+
  2947.         | FillOrder**        | 1: Most significant bit first        |
  2948.         |                    | 2: Least significant bit first       |
  2949.         +--------------------+--------------------------------------+
  2950.         | ImageDescription*  | {ASCII}: A string describing the     |
  2951.         |                    | contents of the image.               |
  2952.         +--------------------+--------------------------------------+
  2953.         | ImageWidth         | 864, 1024, 1216, 1728**, 2048, 2432, |
  2954.         |                    | 2592, 3072, 3456, 3648, 4096, 4864   |
  2955.         +--------------------+--------------------------------------+
  2956.         | ImageLength**      | n: total number of scanlines in image|
  2957.         +--------------------+--------------------------------------+
  2958.         | NewSubFileType     | 2: Bit 1 identifies single page of a |
  2959.         |                    | multi-page document                  |
  2960.         +--------------------+--------------------------------------+
  2961.         | Orientation        | 1**-8, Default 1                     |
  2962.         +--------------------+--------------------------------------+
  2963.         | PhotometricInter-  | 2: RGB                               |
  2964.         | pretation          | 5: CMYK                              |
  2965.         |                    | 10: ITULAB                           |
  2966.         +--------------------+--------------------------------------+
  2967.  
  2968.  
  2969.  
  2970. McIntyre, et. al.           Standards Track                    [Page 53]
  2971.  
  2972. RFC 2301              File Format for Internet Fax            March 1998
  2973.  
  2974.  
  2975.         +--------------------+--------------------------------------+
  2976.         | ResolutionUnit     | 2: inch                              |
  2977.         |                    | 3: centimeter                        |
  2978.         +--------------------+--------------------------------------+
  2979.         | RowsPerStrip       | n: number of scanlines per TIFF strip|
  2980.         +--------------------+--------------------------------------+
  2981.         | SamplesPerPixel    | 1: L* (lightness)                    |
  2982.         |                    | 3: LAB, RGB, CMY                     |
  2983.         |                    | 4: CMYK                              |
  2984.         +--------------------+--------------------------------------+
  2985.         | Software*          | {ASCII}: name & release number of    |
  2986.         |                    | creator software                     |
  2987.         +--------------------+--------------------------------------+
  2988.         | StripByteCounts    | <n>: number or bytes in TIFF strip   |
  2989.         +--------------------+--------------------------------------+
  2990.         | StripOffsets       | <n>: offset from beginning of file to|
  2991.         |                    | each TIFF strip                      |
  2992.         +--------------------+--------------------------------------+
  2993.         | XResolution        | 100, 200, 300, 400 (written in       |
  2994.         |                    | pixels/inch)                         |
  2995.         +--------------------+--------------------------------------+
  2996.         | YResolution        | equal to XResolution (pixels must be |
  2997.         |                    | square)                              |
  2998.         +--------------------+--------------------------------------+
  2999.         | Extension Fields                                          |
  3000.         +--------------------+--------------------------------------+
  3001.         | DocumentName*      | {ASCII}: name of scanned document    |
  3002.         +--------------------+--------------------------------------+
  3003.         | PageNumber         | n,m: page number followed by total   |
  3004.         |                    | page count                           |
  3005.         +--------------------+--------------------------------------+
  3006.         | Indexed            | 0: not a palette-color image         |
  3007.         |                    | 1: palette-color image               |
  3008.         +--------------------+--------------------------------------+
  3009.         | New Fields                                                |
  3010.         +--------------------+--------------------------------------|
  3011.         | Decode             | minL, maxL, mina, maxa, minb, maxb:  |
  3012.         |                    |minimum and maximum values for L*a*b* |
  3013.         +--------------------+--------------------------------------+
  3014.         | GlobalParameters   | IFD: global parameters IFD           |
  3015.         | IFD*               |                                      |
  3016.         +-----------------------------------------------------------+
  3017.  
  3018.  
  3019.  
  3020.  
  3021.  
  3022.  
  3023.  
  3024.  
  3025.  
  3026. McIntyre, et. al.           Standards Track                    [Page 54]
  3027.  
  3028. RFC 2301              File Format for Internet Fax            March 1998
  3029.  
  3030.  
  3031.         +--------------------+--------------------------------------+
  3032.         | ProfileType*       | n: type of data stored in TIFF file  |
  3033.         +--------------------+--------------------------------------+
  3034.         | FaxProfile*        | n: ITU-compatible fax mode           |
  3035.         +--------------------+--------------------------------------+
  3036.         | CodingMethods*     | n:compression algorithms used in     |
  3037.         |                    | file                                 |
  3038.         +--------------------+--------------------------------------+
  3039.         | VersionYear*       | byte sequence: year of ITU fax std   |
  3040.         +--------------------+--------------------------------------+
  3041.  
  3042. 8. Mixed Raster Content Mode
  3043.  
  3044.    This section defines the Mixed Raster Content mode or Profile M of
  3045.    TIFF for facsimile. Implementations of this profile are required to
  3046.    implement Profiles S and C, and may optionally implement Profiles F,
  3047.    J and L.
  3048.  
  3049. 8.1. Overview
  3050.  
  3051.    Unlike previous fax modes, which use a single coding method and
  3052.    spatial resolution for an entire fax page, the Mixed Raster Content
  3053.    mode [T.44] enables different coding methods and resolutions within a
  3054.    single page. For example, consider a page that contains black-and-
  3055.    white text, which is best coded with MMR or JBIG, a color bar chart,
  3056.    best coded with JBIG, and a scanned color image, best coded with
  3057.    JPEG. Similarly, while spatial resolution of 400 pixels per inch may
  3058.    be best for the black-and- white text, 200 pixel per inch is usually
  3059.    sufficient for a color image.
  3060.  
  3061.    Rather than applying one coding method and resolution to all
  3062.    elements, MRC allows multiple coders and resolutions within a page.
  3063.    By itself, MRC does not define any new coding methods or resolutions.
  3064.    Instead it defines a 3-layer image model for structuring and
  3065.    combining the scanned image data. The MRC 3-layer model has been
  3066.    applied here using the TIFF format to yield a data structure which
  3067.    differs from [T.44] though it applies the same coding methods, uses
  3068.    the same compressed image data stream and is consistent with the TIFF
  3069.    principle of a single IFD per image.
  3070.  
  3071. 8.1.1. MRC 3-layer model
  3072.  
  3073.    The 3 layers of the MRC model are Foreground and Background, which
  3074.    are both multi-level, and Mask, which is bi-level. Each layer may
  3075.    appear only once on a page and is coded independently of the other
  3076.    two. In our earlier example, the black-and-white text could be in the
  3077.    Mask layer, the color chart in the Foreground layer, and the color
  3078.    image in the Background layer.
  3079.  
  3080.  
  3081.  
  3082. McIntyre, et. al.           Standards Track                    [Page 55]
  3083.  
  3084. RFC 2301              File Format for Internet Fax            March 1998
  3085.  
  3086.  
  3087.    Each layer is an image and, when present, is represented by at least
  3088.    one IFD in a TIFF file. This is consistent with TIFF, which provides
  3089.    fields to define the attributes, such as resolution, image size, bits
  3090.    per sample, etc., of a single image or layer. The distribution of
  3091.    content among layers is determined by the writer, as is the choice of
  3092.    coding method, color encoding and spatial resolution for a layer.
  3093.  
  3094.    The final image is obtained by using the Mask layer to select pixels
  3095.    from the other two layers. When the Mask layer pixel value is 1, the
  3096.    corresponding pixel from the Foreground layer is selected; when it is
  3097.    0, the corresponding pixel from the Background layer is selected.
  3098.    Details are given in the Introduction of [T.44].
  3099.  
  3100.    Not all pages, and not all parts of a page, require 3 layers. If
  3101.    there is only one layer present, then that layer is the primary image
  3102.    or IFD. If there is more than one layer, then the Mask must be one of
  3103.    the layers, in which case it is the primary image and it must be page
  3104.    size.
  3105.  
  3106.    MRC allows a page to be split into strips, with a variable number of
  3107.    scanlines in a strip. A strip can have 1, 2 or 3 layers. A single,
  3108.    stripped layer may be stored as a single, stripped image in an IFD,
  3109.    e.g., all strips associated with the Background layer may be treated
  3110.    as a single image. Alternatively, each strip associated with a layer
  3111.    may be stored as a separate image or IFD, e.g., the Background layer
  3112.    can be composed of several images that are offset vertically with
  3113.    respect to the page. In this case, there can be no overlap between
  3114.    images associated with a single layer. According to [T.4] Annex G,
  3115.    strips having more than 1 layer SHOULD NOT be more than 256 lines in
  3116.    length unless the capability to receive longer strips has been
  3117.    negotiated.
  3118.  
  3119.    Furthermore, color fax also requires the spatial resolutions of
  3120.    Background and Foreground images to be legal fax values that are also
  3121.    integer factors of the Mask image resolution. For example, if the
  3122.    Mask Layer resolution is 400 pixels per inch, then allowed
  3123.    resolutions for the Foreground and Background layers are 100, 200 or
  3124.    400 pixels per inch; if the Mask is at 300 pixels per inch, then
  3125.    allowed values are 100 and 300. The Foreground and Background layer
  3126.    resolutions can be independently set.
  3127.  
  3128. 8.1.2. A TIFF Representation for the MRC 3-layer model
  3129.  
  3130.    In the TIFF representation of the 3-layer MRC model, each page is
  3131.    represented by a single IFD, called the Primary IFD, that represents
  3132.    the Mask layer (unless the Foreground or Background is the single
  3133.    layer present), and a set of child IFDs that are referenced through
  3134.    the SubIFDs extension field [TTN1]. To distinguish MRC-specific
  3135.  
  3136.  
  3137.  
  3138. McIntyre, et. al.           Standards Track                    [Page 56]
  3139.  
  3140. RFC 2301              File Format for Internet Fax            March 1998
  3141.  
  3142.  
  3143.    SubIFDs from other SubIFDs, the NewSubFileType field MUST have Bit 4
  3144.    ON, indicating an MRC-related IFD. A new ImageLayer field is also
  3145.    introduced that consists of two values that identify the layer
  3146.    (Foreground, Background, or Mask) and the order within the layer
  3147.    (first, second, ... image of the layer); see Section 8.2.3.
  3148.  
  3149.    Because MRC allows strips with variable numbers of scanlines, a
  3150.    reader MUST support StripRowCounts field because a writer may use it
  3151.    in place of the RowsPerStrip field in this mode. The StripRowCounts
  3152.    field allows each layer, with a variable number of scanlines in each
  3153.    strip, to be represented by a single IFD, when the coding parameters
  3154.    are the same for all strips in the layer. The MRC standard [T.44]
  3155.    allows the Foreground and Background layers to have strips with
  3156.    different coding parameters. In this case, a separate IFD is required
  3157.    to represent the strips which use different coding parameters; see
  3158.    text in next paragraph. In all cases, the Mask layer is required to
  3159.    be represented by a single IFD and a single set of coding parameters.
  3160.  
  3161.    The use of SubIFDs to store child IFDs is described in [TTN1]. An
  3162.    example is shown graphically below. The Primary IFD associated with
  3163.    page 1 (PrimaryIFD 0) points to page 2 (PrimaryIFD 1) with the
  3164.    nextIFD offset. The Primary IFD, corresponding to the Mask layer
  3165.    (ImageLayer=[2,1]), contains a SubIFDs field that points to a list of
  3166.    child IFDs. The first child IFD represents one image of the
  3167.    Background layer, i.e., ImageLayer=[1,1]. This child IFD points to
  3168.    the second child IFD via the nextIFD offset. This child represents
  3169.    the second Background layer image, ImageLayer=[1,2]. Finally, the
  3170.    second child points to the third child, which corresponds to the
  3171.    single Foreground layer image, ImageLayer=[3,1]. The next IFD offset
  3172.    associated with this Foreground image is 0, indicating no more child
  3173.    IFDs exist. Each primary IFD has the NewSubFileType set to 18,
  3174.    indicating the IFD is MRC-specific (bit 4) and that it is a single
  3175.    page of a multi-page document (bit 1). Each child IFD has the
  3176.    NewSubFileType set to 16, indicating the IFD is MRC-specific. The 'V'
  3177.    character should be read as a down-pointing arrow.
  3178.  
  3179.                        (nextIFD)
  3180.        PRIMARY IFD 0  ------------> PRIMARY IFD 1--> ...
  3181.            ImageLayer = [2,1]
  3182.            NewSubFileType = 18
  3183.            SubIFDs
  3184.                 |
  3185.                 V
  3186.              Child IFD
  3187.                 ImageLayer = [1,1]
  3188.                 NewSubFileType = 16
  3189.                 |
  3190.                 |(nextIFD)
  3191.  
  3192.  
  3193.  
  3194. McIntyre, et. al.           Standards Track                    [Page 57]
  3195.  
  3196. RFC 2301              File Format for Internet Fax            March 1998
  3197.  
  3198.  
  3199.                 |
  3200.                 V
  3201.              Child IFD
  3202.                 ImageLayer = [1,2]
  3203.                 NewSubFileType = 16
  3204.                 |
  3205.                 |(nextIFD)
  3206.                 |
  3207.                 V
  3208.              Child IFD
  3209.                 ImageLayer = [3,1]
  3210.                 NewSubFileType = 16
  3211.                 |
  3212.                 |(nextIFD)
  3213.                 V
  3214.                 0
  3215.  
  3216.    In the example above, the SubIFDs field of the Primary IFD points to
  3217.    the first IFD in a list of child IFDs. TIFF allows the SubIFDs field
  3218.    to point to an array of IFDs, each of which can be the first of a
  3219.    list of IFDs. An MRC-enabled TIFF reader must scan all available
  3220.    child IFDs to locate and identify IFDs associated with MRC layers.
  3221.  
  3222.    In the case where the Background or Foreground layers are described
  3223.    with multiple IFDs, the XPosition and YPosition TIFF fields specify
  3224.    the offset to the upper-left corner of the IFD with respect to the
  3225.    Mask layer; see Section 8.2.2. When there is only a single layer
  3226.    (Mask, Foreground, or Background), it is stored as the Primary IFD.
  3227.  
  3228. 8.2. Required TIFF Fields
  3229.  
  3230.    This section describes the TIFF fields required, in addition to those
  3231.    in Section 2.2.1, to represent MRC mode fax images. Since MRC mode
  3232.    stores fax data as a collection of images corresponding to layers or
  3233.    parts of layers, the coding methods, color encodings and spatial
  3234.    resolutions used by previous modes apply to MRC. Therefore, the
  3235.    descriptions here will typically reference the appropriate earlier
  3236.    section. Fields and values specific to MRC mode are pointed out.
  3237.  
  3238. 8.2.1. Baseline Fields
  3239.  
  3240. ImageWidth(256).                                           SHORT or LONG
  3241.     Same page widths as the base color mode; see Section 6.2.1.
  3242.     In the MRC mode, the width of a Foreground or Background image in
  3243.     the coded data stream may be less than the page width. In this case,
  3244.     the image width in the coded data steam is used to interpret the
  3245.     coded data, and the value of this field is used as the page width.
  3246.  
  3247.  
  3248.  
  3249.  
  3250. McIntyre, et. al.           Standards Track                    [Page 58]
  3251.  
  3252. RFC 2301              File Format for Internet Fax            March 1998
  3253.  
  3254.  
  3255. NewSubFileType(254) = 16, 18.                                       LONG
  3256.     For MRC fax mode, the NewSubFileType field has two bits that are
  3257.     required.
  3258.     Bit 1 indicates a single page of a multi-page document and must be
  3259.     set for the Primary IFD;
  3260.     Bit 4 indicates MRC imaging model as described in ITU-T
  3261.     Recommendation T.44 [T.44], and must be set for Primary IFDs
  3262.     and all MRC-specific child IFDs.
  3263.  
  3264. BitsPerSample(258) = 1, 2-8, 9-16                                  SHORT
  3265. Compression(259) = 3, 4, 7, 9, 10.                                 SHORT
  3266. SamplesPerPixel(277) = 1, 3, 4.                                    SHORT
  3267.  
  3268. FillOrder(266) = 1 , 2.                                            SHORT
  3269.     RequiredByTIFFBaseline
  3270.     Profile F readers must be able to read data in both bit orders,
  3271.     but the vast majority of facsimile products store data LSB
  3272.     first, exactly as it appears on the telephone line.
  3273.               1 = Most Significant Bit first.
  3274.               2 = Least Significant Bit first
  3275.  
  3276. ResolutionUnit(296) = 2, 3.                                        SHORT
  3277. PhotometricInterpretation(262) = 0, 1, 2, 5, 10.                   SHORT
  3278.     For Mask layer, see Sections 4.2.1 and 5.2.1.
  3279.     For Foreground and Background layers, see Sections 6.2.1 and 7.2.1.
  3280.  
  3281. ColorMap(320).                                                     SHORT
  3282. Count = 3 * (2**BitsPerSample)
  3283.     Used when Foreground or Background layer is a palette-color image;
  3284.     see Section 7.2.1.
  3285.  
  3286. XResolution(282) = 100, 200, 300, 400.                          RATIONAL
  3287. YResolution(283) = 100, 200, 300, 400.                          RATIONAL
  3288.     The resolution of the image is expressed in pixels per resolution
  3289.     unit. In pixels per inch, allowed XResolution values for all layers
  3290.     are: 100, 200, 300, and 400. MRC color fax mode requires the pixels
  3291.     to be square, hence YResolution must equal XResolution for all
  3292.     layers. The resolution of Background and Foreground layers must each
  3293.     be an integer factor of the Primary image, which is the Mask layer,
  3294.     when it is present; see Section 8.4.
  3295.     See Section 2.2.2 for inch-metric equivalency.
  3296.  
  3297. 8.2.2. Extension Fields
  3298.  
  3299. ChromaSubSampling(530).                                            SHORT
  3300. ChromaPositioning(531).                                            SHORT
  3301.     For Foreground and Background layers, see Section 6.2.2.
  3302.  
  3303.  
  3304.  
  3305.  
  3306. McIntyre, et. al.           Standards Track                    [Page 59]
  3307.  
  3308. RFC 2301              File Format for Internet Fax            March 1998
  3309.  
  3310.  
  3311. Indexed(346) = 0, 1.                                               SHORT
  3312.     For Foreground and Background layers: 1 indicates a palette-color
  3313.     image, see Section 7.2.2.
  3314.  
  3315. T4Options(292) = 0, 1, 4, 5.                                       SHORT
  3316. T6Options(293) = 0.                                                SHORT
  3317.     For Mask layer, see Section 4.2.2.
  3318.  
  3319. SubIFDs(330).                                                        IFD
  3320.     Count = number of child IFDs
  3321.     Each value is an offset from the beginning of the TIFF file to a
  3322.     child IFD [TTN1].
  3323.  
  3324. XPosition(286).                                                 RATIONAL
  3325. YPosition(287).                                                 RATIONAL
  3326.     Specifies the horizontal and vertical offsets of the top-left of the
  3327.     IFD from the top-left of the Primary IFD in page resolution units.
  3328.     For example, if the Primary IFD is at 400 pixels per inch, and a
  3329.     foreground layer IFD is at 200 pixels per inch and located at pixel
  3330.     coordinate (345, 678) with respect to the Primary IFD, the XPosition
  3331.     value is 345/400 and the YPosition value is 678/400.
  3332.     Color fax does not currently allow overlap of any component images
  3333.     within a single layer.
  3334.     Default values for XPosition and YPosition are 0.
  3335.  
  3336. 8.2.3. New Fields
  3337.  
  3338. Decode(433).                                                   SRATIONAL
  3339.     For Foreground and Background layers, see Section 6.2.3.
  3340.  
  3341. DefaultImageColor(434).                                            SHORT
  3342.     Count = SamplesPerPixel
  3343.     In areas where no image data is available, a default color is needed
  3344.     to specify the color value. If the StripByteCounts value for a strip
  3345.     is 0, then the color for that strip must be defined by a default
  3346.     image color.
  3347.  
  3348.     The DefaultImageColor field uses the same encoding as the image
  3349.     data, and its value is therefore interpreted using the
  3350.     PhotometricInterpretation, SamplesPerPixel, BitsPerSample, and
  3351.     Indexed fields. If the fax data stream requires a different
  3352.     encoding, then transferring the default color value between a TIFF
  3353.     file and fax data stream requires a color conversion.
  3354.     For the Foreground layer image, the default value for the
  3355.     DefaultImageColor field is black. For other cases, including the
  3356.     Background layer image, the default value is white.
  3357.  
  3358.  
  3359.  
  3360.  
  3361.  
  3362. McIntyre, et. al.           Standards Track                    [Page 60]
  3363.  
  3364. RFC 2301              File Format for Internet Fax            March 1998
  3365.  
  3366.  
  3367. StripRowCounts(559).                                                LONG
  3368.     Count = number of strips
  3369.     The number of scanlines stored in a strip. MRC allows each fax strip
  3370.     to store a different number of scanlines. For strips with more than
  3371.     one layer there is a maximum strip size of 256 scanlines or full
  3372.     page size. The 256 maximum SHOULD be used unless the capability to
  3373.     receive longer strips has been negotiated. This field replaces
  3374.     RowsPerStrip for IFDs with variable-sized strips. Only one of the
  3375.     two fields, StripRowCounts and RowsPerStrip, may be used in an IFD.
  3376.  
  3377. ImageLayer (34732).                                       SHORT or LONG.
  3378.     Count = 2
  3379.     Image layers are defined such that layer 1 is the Background layer,
  3380.     layer 3 is the Foreground layer, and layer 2 is the Mask layer,
  3381.     which selects pixels from the Background and Foreground layers. The
  3382.     ImageLayer tag contains two values, describing the layer to which
  3383.     the image belongs and the order in which it is imaged.
  3384.  
  3385.     ImageLayer[0] = 1, 2, 3.
  3386.     1: Image is a Background image, i.e., the image that will appear
  3387.        whenever the Mask contains a value of 0. Background images
  3388.        typically contain low-resolution, continuous-tone imagery.
  3389.     2: Image is the Mask layer. In MRC, if the Mask layer is present, it
  3390.        must be the Primary IFD and be full page in extent (no gaps.)
  3391.     3: Image is a Foreground image, i.e., the image that will appear
  3392.        whenever the Mask contains a value of 1. The Foreground image
  3393.        generally defines the color of text or lines, but may also
  3394.        contain high-resolution imagery.
  3395.  
  3396.     ImageLayer[1]:
  3397.     1: first image to be imaged in this layer,
  3398.     2: second image to be imaged in this layer,
  3399.     3: ...
  3400.  
  3401.     Value describing the image order. In MRC, this may be considered
  3402.     the strip number. Since MRC mode currently does not allow overlap
  3403.     between images within a layer, the order value does not have any
  3404.     visual effect.
  3405.  
  3406.    In MRC fax mode, it is possible that only a single layer is
  3407.    transmitted. For example, if a page contains only a single
  3408.    continuous-tone photograph, then only the Background layer may be
  3409.    transmitted. In this case, the Background layer will be stored as the
  3410.    Primary IFD. ImageLayer[0] will be 1 indicating Background;
  3411.    ImageLayer[1] will be 1 since there can be no other IFDs associated
  3412.    with that layer. No Mask layer will exist.
  3413.  
  3414.  
  3415.  
  3416.  
  3417.  
  3418. McIntyre, et. al.           Standards Track                    [Page 61]
  3419.  
  3420. RFC 2301              File Format for Internet Fax            March 1998
  3421.  
  3422.  
  3423. 8.3. Recommended TIFF Fields
  3424.  
  3425.    See Sections 2.2.3. and 2.2.4.
  3426.  
  3427. 8.4. Rules and Requirements for Images
  3428.  
  3429.    The MRC mode defines a fundamental set of rules for images in the 3-
  3430.    layer representation.
  3431.  
  3432.    1. If more than one layer exists, then the binary Mask layer SHALL be
  3433.       present and be the primary image. The Mask layer SHALL support the
  3434.       encoding defined in Section 3 and MAY support the encodings
  3435.       defined in Sections 4 and 5. If only one layer exists, then the
  3436.       image corresponding to that layer is the primary image.
  3437.  
  3438.    2. When the binary Mask layer is the Primary IFD, the Primary IFD
  3439.       defines and extends to the entire page boundary; all attached
  3440.       model images cannot extend beyond the Primary image. Resolution
  3441.       differences may cause some pixels to "hang over" the page
  3442.       boundary, but no new pixels should exist completely beyond the
  3443.       page extent. When the Foreground or Background layer is the
  3444.       Primary IFD, the Primary IFD may not be page width.
  3445.  
  3446.    3. The Background and Foreground images SHALL support the color
  3447.       encoding defined in Section 6 and MAY support the color encoding
  3448.       defined in Section 7. These images MAY optionally cover only a
  3449.       portion of the strip or page.
  3450.  
  3451.    4. Each Primary IFD and each MRC-specific SubIFD must have an
  3452.       ImageLayer field to specify which layer the IFD belongs to, and
  3453.       the imaging order of that IFD within the layer.
  3454.  
  3455.    5. Each Primary IFD must have a NewSubFileType field value set to 18,
  3456.       indicating a single page of a multi-page document (bit 1) and MRC
  3457.       mode (bit 4).
  3458.  
  3459.    6. Each MRC-specific child IFD must have a NewSubFileType field value
  3460.       set to 16, indicating MRC mode (bit 4).
  3461.  
  3462.    7. In MRC mode, each layer is transmitted as a sequence of strips. It
  3463.       is possible that each strip of each layer can be stored as a
  3464.       separate IFD. In this case, the SubIFDs structure pointed to by
  3465.       the Primary IFD will contain several IFDs that have an ImageLayer
  3466.       field with the layer identified as either Background (layer 1) or
  3467.       Foreground (layer 3). There may be no overlap in the vertical
  3468.       direction between IFDs associated with a single layer, although
  3469.  
  3470.  
  3471.  
  3472.  
  3473.  
  3474. McIntyre, et. al.           Standards Track                    [Page 62]
  3475.  
  3476. RFC 2301              File Format for Internet Fax            March 1998
  3477.  
  3478.  
  3479.       there may be a gap from one of these images to the next. The TIFF
  3480.       XPosition and YPosition fields are used to indicate the placement
  3481.       of these images with respect to the primary image.
  3482.  
  3483.    8. When the Mask image is present, the resolution of Background and
  3484.       Foreground images must each be an integer factor of the Mask
  3485.       image. For example, if the Mask image is 400 pixels/inch, then the
  3486.       Background or Foreground image may be at 400 pixels/inch (400/1),
  3487.       200 pixels/inch (400/2) or 100 pixels/inch (400/4).
  3488.  
  3489. 8.5. MRC Fax Mode Summary
  3490.  
  3491.    Recommended fields are shown with an asterisk *
  3492.  
  3493.        +------------------+-----------------------------------------+
  3494.        | Baseline Fields  |               Values                    |
  3495.        |------------------|-----------------------------------------|
  3496.        | BitsPerSample    | 1: binary mask                          |
  3497.        |                  | 8: 8 bits per color sample              |
  3498.        |                  | 9-16: optional 12 bits/sample           |
  3499.        +------------------+-----------------------------------------+
  3500.        | ColorMap         | n: LAB color map                        |
  3501.        +------------------+-----------------------------------------+
  3502.        | Compression      | 3: Modified Huffman and Modified Read   |
  3503.        |                  | 4: Modified Modified Read               |
  3504.        |                  | 7: JPEG                                 |
  3505.        |                  | 9: JBIG, per T.85                       |
  3506.        |                  | 10: JBIG, per T.43                      |
  3507.        +------------------+-----------------------------------------+
  3508.        | DateTime*        | {ASCII): date/time in the 24-hour format|
  3509.        |                  | "YYYY:MM:DD HH:MM:SS"                   |
  3510.        +------------------+-----------------------------------------|
  3511.        | FillOrder**      | 1: Most significant bit first           |
  3512.        |                  | 2: Least significant bit first          |
  3513.        +------------------+-----------------------------------------|
  3514.        | ImageDescription*| {ASCII}: A string describing the        |
  3515.        |                  | contents of the image.                  |
  3516.        +------------------+-----------------------------------------+
  3517.        | ImageWidth       | 864, 1024, 1216, 1728**, 2048, 2432,    |
  3518.        |                  | 2592, 3072, 3456, 3648, 4096, 4864      |
  3519.        +------------------+-----------------------------------------+
  3520.        | ImageLength**    | n: total number of scanlines in image   |
  3521.        +------------------+-----------------------------------------+
  3522.        | NewSubFileType   | 16, 18:                                 |
  3523.        |                  | Bit 1 indicates single page of a multi- |
  3524.        |                  | page document on Primary IFD            |
  3525.        |                  | Bit 4 indicates MRC model               |
  3526.        +------------------+-----------------------------------------+
  3527.  
  3528.  
  3529.  
  3530. McIntyre, et. al.           Standards Track                    [Page 63]
  3531.  
  3532. RFC 2301              File Format for Internet Fax            March 1998
  3533.  
  3534.  
  3535.        +------------------+-----------------------------------------+
  3536.        | Orientation      | 1**-8, Default 1                        |
  3537.        +------------------+-----------------------------------------+
  3538.        | PhotometricInter | 0: WhiteIsZero                          |
  3539.        | pretation        | 1: BlackIsZero                          |
  3540.        |                  | 2: RGB                                  |
  3541.        |                  | 5: CMYK                                 |
  3542.        |                  | 10: ITULAB                              |
  3543.        +------------------+-----------------------------------------+
  3544.        | ResolutionUnit   | 2: inch                                 |
  3545.        |                  | 3: centimeter                           |
  3546.        +------------------+-----------------------------------------+
  3547.        | RowsPerStrip     | n: number or scanlines per strip        |
  3548.        +------------------+-----------------------------------------+
  3549.        | SamplesPerPixel  | 1: L* (lightness)                       |
  3550.        |                  | 3: RGB, LAB, CMY                        |
  3551.        |                  | 4: CMYK                                 |
  3552.        +------------------+-----------------------------------------+
  3553.        | Software*        | {ASCII}: name & release number of       |
  3554.        |                  | creator software                        |
  3555.        +------------------+-----------------------------------------+
  3556.        | StripByteCounts  | <n>: number or bytes in each strip      |
  3557.        +------------------+-----------------------------------------+
  3558.        | StripOffsets     | <n>: offset from beginning of file to   |
  3559.        |                  | each TIFF strip                         |
  3560.        +------------------+-----------------------------------------|
  3561.        | XResolution      | 100, 200, 300, 400 (written in          |
  3562.        |                  | pixels/inch)                            |
  3563.        +------------------+-----------------------------------------|
  3564.        | YResolution      | equal to XResolution (pixels must be    |
  3565.        |                  | square)                                 |
  3566.        +------------------+-----------------------------------------+
  3567.        | Extension Fields                                           |
  3568.        +------------------+-----------------------------------------+
  3569.        | T4Options        | 0: required if Compression is Modified  |
  3570.        |                  | Huffman, EOLs not byte aligned          |
  3571.        |                  | 1: required if Compression 2D Modified  |
  3572.        |                  | Read, EOLs are not byte aligned         |
  3573.        |                  | 4: required if Compression Modified     |
  3574.        |                  | Huffman, EOLs byte aligned              |
  3575.        |                  | 5: required if Compression 2D Modified  |
  3576.        |                  | Read, EOLs are byte aligned             |
  3577.        +------------------+-----------------------------------------+
  3578.        | T6Options        | 0: required if Compression is 2D        |
  3579.        |                  | Modified Modified Read                  |
  3580.        +------------------+-----------------------------------------+
  3581.  
  3582.  
  3583.  
  3584.  
  3585.  
  3586. McIntyre, et. al.           Standards Track                    [Page 64]
  3587.  
  3588. RFC 2301              File Format for Internet Fax            March 1998
  3589.  
  3590.  
  3591.        +------------------+-----------------------------------------+
  3592.        | DocumentName*    | {ASCII}: name of scanned document       |
  3593.        +------------------+-----------------------------------------+
  3594.        | PageNumber       | n,m: page number followed by total page |
  3595.        |                  | count                                   |
  3596.        +------------------+-----------------------------------------+
  3597.        | ChromaSubSampling| (1,1), (2, 2)**                         |
  3598.        |                  | (1, 1): equal numbers of lightness and  |
  3599.        |                  | chroma samples horizontally & vertically|
  3600.        |                  | (2, 2): twice as many lightness samples |
  3601.        |                  | as chroma horizontally and vertically   |
  3602.        +------------------+-----------------------------------------+
  3603.        | ChromaPositioning| 1: centered                             |
  3604.        +------------------+-----------------------------------------+
  3605.        | Indexed          | 0: not a palette-color image            |
  3606.        |                  | 1: palette-color image                  |
  3607.        +------------------+-----------------------------------------+
  3608.        | SubIFDs          | <IFD>: byte offset to fg/ ImageLayer tag c       +------------------+-----------------------------------------+
  3609.        | XPosition        | horizontal offset in primary IFD        |
  3610.        |                  | resolution units                        |
  3611.        +------------------+-----------------------------------------+
  3612.        | YPosition        | vertical offset in primary IFD          |
  3613.        |                  | resolution units                        |
  3614.        +------------------+-----------------------------------------+
  3615.        | New Fields                                                 |
  3616.        +------------------+-----------------------------------------+
  3617.        | Decode           | minL, maxL, mina, maxa, minb, maxb:     |
  3618.        |                  | minimum and maximum values for L*a*b*   |
  3619.        +------------------+-----------------------------------------+
  3620.        | DefaultImageColor| <n>: background color                   |
  3621.        +------------------+-----------------------------------------+
  3622.        | StripRowCounts   | <n>: number of scanlines in each strip  |
  3623.        +------------------+-----------------------------------------+
  3624.        | ImageLayer       | n, m: layer number, imaging sequence    |
  3625.        |                  | (e.g., strip number)                    |
  3626.        +------------------+-----------------------------------------+
  3627.        | GlobalParameters | IFD: global parameters IFD              |
  3628.        | IFD*             |                                         |
  3629.        +------------------+-----------------------------------------+
  3630.        | ProfileType*     | n: type of data stored in TIFF file     |
  3631.        +------------------+-----------------------------------------+
  3632.        | FaxProfile*      | n: ITU-compatible fax mode              |
  3633.        +------------------+-----------------------------------------+
  3634.        | CodingMethods*   | n: compression algorithms used in file  |
  3635.        +------------------+-----------------------------------------+
  3636.        | ModeNumber*      | n: version of ITU fax standard          |
  3637.        +------------------+-----------------------------------------+
  3638.  
  3639.  
  3640.  
  3641. McIntyre, et. al.           Standards Track                    [Page 65]
  3642.  
  3643. RFC 2301              File Format for Internet Fax            March 1998
  3644.  
  3645.  
  3646.        +------------------------------------------------------------+
  3647.        | VersionYear*     | byte sequence: year of ITU fax standard |
  3648.        +------------------+-----------------------------------------+
  3649.  
  3650. 9. MIME content-type image/tiff
  3651.  
  3652.    [TIFF-REG] describes the registration of the MIME content-type
  3653.    image/tiff to refer to TIFF encoded image data. When transported by
  3654.    MIME, the TIFF content defined by this document must be encoded
  3655.    within an image/tiff content type. In addition, an optional
  3656.    "application" parameter is defined for image/tiff to identify a
  3657.    particular application's subset of TIFF and TIFF extensions for the
  3658.    encoded image data, if it is known. Typically, this would be used to
  3659.    assist the recipient in dispatching a suitable rendering package to
  3660.    handle the display or processing of the image file.
  3661.  
  3662. 9.1 Refinement of MIME content-type image/tiff for Facsimile
  3663.    Applications
  3664.  
  3665.    Since this document defines facsimile specific profiles of TIFF, it
  3666.    is useful to note an appropriate application parameter for the
  3667.    image/tiff MIME content-type.
  3668.  
  3669.    The two values of the image/tiff application parameter as defined for
  3670.    facsimile are shown below, separated by a comma:
  3671.  
  3672.        faxbw, faxcolor
  3673.  
  3674.    The "faxbw" application parameter is suitable for use by applications
  3675.    that can process one or more TIFF for facsimile profiles or subsets
  3676.    used for the encoding of black and white facsimile data.
  3677.  
  3678.    The "faxcolor" application parameter is suitable for use by
  3679.    applications that can process one or more TIFF for facsimile profiles
  3680.    or subsets that can be used for the encoding of black and white, AND
  3681.    color facsimile data.
  3682.  
  3683.    Since this document defines several profiles of TIFF for facsimile,
  3684.    the following rules should be followed when setting the application
  3685.    parameter value. For TIFF image data which is encoded for the
  3686.    profiles of TIFF for Facsimile that support black-and-white image
  3687.    data (Profiles S, F or J), applications which use one of these
  3688.    profiles or a subset should set the value of the application
  3689.    parameter to "faxbw". For TIFF image data which is encoded for the
  3690.    defined profiles of TIFF for Facsimile that support color image data
  3691.    (Profiles C, L or M), as well as black-and-white image data,
  3692.    applications which use one of these profiles or a subset should set
  3693.    the value of the application parameter to "faxcolor".
  3694.  
  3695.  
  3696.  
  3697. McIntyre, et. al.           Standards Track                    [Page 66]
  3698.  
  3699. RFC 2301              File Format for Internet Fax            March 1998
  3700.  
  3701.  
  3702.    An example of the use of the image/tiff MIME Content-type with the
  3703.    application parameter set with the value 'faxbw' follows:
  3704.  
  3705.        Content-type: image/tiff; application=faxbw
  3706.  
  3707.    In this example, use of this parameter value will enable applications
  3708.    to identify the content as being within a profile or subset of TIFF
  3709.    for Facsimile that is suitable for encoding black and white image
  3710.    data, Before attempting to process the image data.
  3711.  
  3712.    In a similar respect, an example of the image/tiff MIME Content-type
  3713.    with the application parameter setting suitable for handling a color
  3714.    subset or profile of TIFF for facsimile is shown below:
  3715.  
  3716.        Content-type: image/tiff; application=faxcolor
  3717.  
  3718. 10. Security Considerations
  3719.  
  3720.    This document describes a file format for Internet fax, which is a
  3721.    series of profiles of TIFF for facsimile. As such, it does not create
  3722.    any security issues not already identified in [TIFF-REG], in its use
  3723.    of fields as defined in [TIFF].  There are also new TIFF fields
  3724.    defined within this specification, but they are of a purely
  3725.    descriptive nature, so that no new security risks are incurred.
  3726.  
  3727.    Further, the encoding specified in this document does not in any way
  3728.    preclude the use of any Internet security protocol to encrypt,
  3729.    authenticate, or non-repudiate TIFF-encoded facsimile messages.
  3730.  
  3731. 11. References
  3732.  
  3733.    [REQ] Bradner, S, "Key words for use in RFCs to Indicate Requirement
  3734.    Levels", RFC 2119, March 1997.
  3735.  
  3736.    [T.4] ITU-T Recommendation T.4, Standardization of group 3 facsimile
  3737.    apparatus for document transmission, October 1997
  3738.  
  3739.    [T.6] ITU-T Recommendation T.6, Facsimile coding schemes and coding
  3740.    control functions for group 4 facsimile apparatus, November 1988
  3741.  
  3742.    [T.30] ITU-T Recommendation T.30 - Procedures for Document Facsimile
  3743.    Transmission in the General Switched Telephone Network, June 1996
  3744.  
  3745.    [T.42] ITU-T Recommendation T.42, Continuous-tone colour
  3746.    representation method for facsimile, February 1996
  3747.  
  3748.  
  3749.  
  3750.  
  3751.  
  3752.  
  3753. McIntyre, et. al.           Standards Track                    [Page 67]
  3754.  
  3755. RFC 2301              File Format for Internet Fax            March 1998
  3756.  
  3757.  
  3758.    [T.43] ITU-T Recommendation T.43, Colour and gray-scale image
  3759.    representations using lossless coding scheme for facsimile, February
  3760.    1997
  3761.  
  3762.    [T.44] ITU-T Recommendation T.44, Mixed Raster Content (MRC), October
  3763.    1997.
  3764.  
  3765.    [T.81] ITU-T Recommendation T.81, Information technology - Digital
  3766.    compression and coding of continuous-tone still images - Requirements
  3767.    and guidelines, September 1992
  3768.  
  3769.    [T.82] ITU-T Recommendation T.82, Information technology - Coded
  3770.    representation of picture and audio information - Progressive bi-
  3771.    level image compression, March 1995
  3772.  
  3773.    [T.85] ITU-T Recommendation T.85, Application profile for
  3774.    Recommendation T.82 - Progressive bi-level image compression (JBIG
  3775.    coding scheme) for facsimile apparatus, August 1995
  3776.  
  3777.    [TIFF] Tag Image File Format, Revision 6.0, Adobe Developers
  3778.    Association, June 3, 1992,
  3779.    ftp://ftp.adobe.com/pub/adobe/devrelations/
  3780.    devtechnotes/pdffiles/tiff6.pdf
  3781.  
  3782.         The TIFF 6.0 specification dated June 3, 1992 specification (c)
  3783.         1986-1988, 1992 Adobe Systems Incorporated. All Rights Reserved.
  3784.  
  3785.    [TIFF-FY] Parsons, G.  and J. Rafferty, "Tag Image File Format (TIFF)
  3786.    - F Profile for Facsimile", RFC 2306, March 1998.
  3787.  
  3788.    [TIFF-F0] TIFF Class F specification, Apr 28, 1990,
  3789.    ftp://ftp.faximum.com/pub/documents/tiff_f.txt
  3790.  
  3791.    [TIFF-REG] Parsons, G., Rafferty J. and S. Zilles, "Tag Image File
  3792.    Format (TIFF) - image/tiff MIME Sub-type Registration",  RFC 2302,
  3793.    March 1998.
  3794.  
  3795.    [TTN1] Adobe PageMaker 6.0 TIFF Technical Notes, Sept. 14, 1995,
  3796.    http://www.adobe.com/supportservice/devrelations/PDFS/TN/TIFFPM6.pdf
  3797.  
  3798.    [TTN2] Draft TIFF Technical Note 2, Replacement TIFF/JPEG
  3799.    specification, March 17, 1995,
  3800.    ftp://ftp.sgi.com/graphics/tiff/TTN2.draft.txt
  3801.  
  3802.    [VPIM2] Vaudreui,l G. and G. Parsons, "Voice Profile for Internet
  3803.    Mail - version 2", work in progress, <draft-ema-vpim-06.txt>
  3804.  
  3805.    The ITU-T Recommendations are available at http://www.itu.ch.
  3806.  
  3807.  
  3808.  
  3809. McIntyre, et. al.           Standards Track                    [Page 68]
  3810.  
  3811. RFC 2301              File Format for Internet Fax            March 1998
  3812.  
  3813.  
  3814. 12. Authors' Addresses
  3815.  
  3816.    Lloyd McIntyre                     Stephen Zilles
  3817.    Xerox Corporation                  Adobe Systems Inc.
  3818.    Mailstop PAHV-305                  Mailstop W14
  3819.    3400 Hillview Ave.                 345 Park Avenue
  3820.    Palo Alto, CA 94304 USA            San Jose, CA 95110-2704, USA
  3821.    Voice: +1-650-813-6762             Voice: +1-408-536-4766
  3822.    Fax: +1-650-845-2340               Fax: +1-408-536-4042
  3823.    Email: lmcintyre@adoc.xerox.com    Email: szilles@adobe.com
  3824.  
  3825.    Robert Buckley                     Dennis Venable
  3826.    Xerox Corporation                  Xerox Corporation
  3827.    Mailstop 0128-30E                  Mailstop 0128-27E
  3828.    800 Phillips Road                  800 Phillips Road
  3829.    Webster, NY 14580, USA             Webster, NY 14580, USA
  3830.    Voice: +1-716-422-1282             Voice: +1-716-422-8009
  3831.    Fax: +1-716-422-6117               Fax: +1-716-422-6117
  3832.    Email: Rob_Buckley@wb.xerox.com    Email: venable@wrc.xerox.com
  3833.  
  3834.    Glenn S. Parsons                   James Rafferty
  3835.    Northern Telecom                   Human Communications
  3836.    P.O. Box 3511, Station C           12 Kevin Drive
  3837.    Ottawa, ON  K1Y 4H7, Canada        Danbury, CT 06811-2901, USA
  3838.    Phone: +1-613-763-7582             Phone: +1-203-746-4367
  3839.    Fax: +1-613-763-2697               Fax: +1-203-746-4367
  3840.    Email: Glenn.Parsons@Nortel.ca     Email: Jrafferty@worldnet.att.net
  3841.  
  3842.  
  3843.  
  3844.  
  3845.  
  3846.  
  3847.  
  3848.  
  3849.  
  3850.  
  3851.  
  3852.  
  3853.  
  3854.  
  3855.  
  3856.  
  3857.  
  3858.  
  3859.  
  3860.  
  3861.  
  3862.  
  3863.  
  3864.  
  3865. McIntyre, et. al.           Standards Track                    [Page 69]
  3866.  
  3867. RFC 2301              File Format for Internet Fax            March 1998
  3868.  
  3869.  
  3870. Annex A:  Summary of TIFF Fields for Internet Fax
  3871.  
  3872.    This annex includes tables which list by mode the TIFF fields used in
  3873.    the proposed fax file format.  The fields are organized into 3
  3874.    categories:
  3875.  
  3876.       1)  TIFF Baseline Fields
  3877.       2)  TIFF Extension Fields
  3878.       3)  New Fields.
  3879.  
  3880.    The tables include the allowed values for each fax mode. Entries
  3881.    other than explicit numbers are described by:
  3882.  
  3883.       n        - single number
  3884.       n, m     - 2 numbers
  3885.       a, b, c  - 3 numbers
  3886.       r        - rational number
  3887.       <n>      - array of numbers
  3888.       <b>      - byte sequence
  3889.       {ASCII}  - string
  3890.       IFD      - IFD byte offset
  3891.       <IFD>    - array of IFD byte offsets
  3892.  
  3893.    A blank entry in the table indicates that the field is not used by
  3894.    that particular fax mode.
  3895.  
  3896. Table A.1  TIFF Baseline Fields
  3897.  
  3898.             +---------------------------------------------------------+
  3899.             |                    Fax Mode/Profile                     |
  3900.             +---------------------------------------------------------|
  3901.             | Minimal | Extended |  JBIG  |  Lossy  |Lossless| Mixed  |
  3902.  +----------|   B&W   |    B&W   |  B&W   |  Color  | Color  | Raster |
  3903.  |   TIFF   |         |          |        |         |        | Content|
  3904.  |  Field   |    S    |     F    |   J    |    C    |   L    |   M    |
  3905.  +----------+---------+----------+--------+---------+--------+--------+
  3906.  | BitsPer  | 1       | 1        | 1      | 8, 12   | 1, 2-8 | 1, 2-8 |
  3907.  | Sample   |         |          |        |         | 9-16   | 9-16   |
  3908.  +----------+---------+----------+--------+---------+--------+--------+
  3909.  | ColorMap |         |          |        |         | <n>    | <n>    |
  3910.  +----------+---------+----------+--------+---------+--------+--------+
  3911.  | Compres- | 3       | 3, 4     | 9      | 7       | 10     | 3, 4, 7|
  3912.  | sion     |         |          |        |         |        | 9,10   |
  3913.  +----------+---------+----------+--------+---------+--------+--------+
  3914.  | DateTime |         | {ASCII}  | {ASCII}| {ASCII} | {ASCII}| {ASCII}|
  3915.  +----------+---------+----------+--------+---------+--------+--------+
  3916.  | FillOrder| 2       | 1, 2     | 1, 2   | 1, 2    | 1, 2   | 1,2    |
  3917.  +----------+---------+----------+--------+---------+--------+--------+
  3918.  
  3919.  
  3920.  
  3921. McIntyre, et. al.           Standards Track                    [Page 70]
  3922.  
  3923. RFC 2301              File Format for Internet Fax            March 1998
  3924.  
  3925.  
  3926.  +----------+---------+----------+--------+---------+--------+--------+
  3927.  | ImageDes-|         | {ASCII}  | {ASCII}| {ASCII} | {ASCII}| {ASCII}|
  3928.  | cription |         |          |        |         |        |        |
  3929.  +----------+---------+----------+--------+---------+--------+--------+
  3930.  | Image-   | n       | n        | n      | n       | n      | n      |
  3931.  | Length   |         |          |        |         |        |        |
  3932.  +----------+---------+----------+--------+---------+--------+--------+
  3933.  | Image-   | 1728    | 1728, 2048, 2432  |   864, 1024, 1216, 1728,  |
  3934.  | Width    |         | 2592, 3072, 3456  |  2048, 2432, 2592, 3072,  |
  3935.  |          |         | 3648, 4096, 4864  |  3456, 3648, 4096, 4864   |
  3936.  +----------+---------+----------+--------+---------+--------+--------+
  3937.  | NewSub-  | 2       | 2        | 2      | 2       | 2      | 16, 18 |
  3938.  | FileType |         |          |        |         |        |        |
  3939.  +----------+---------+----------+--------+---------+--------+--------+
  3940.  | Orien-   | 1       | 1-8      | 1-8    | 1-8     | 1-8    | 1-8    |
  3941.  | tation   |         |          |        |         |        |        |
  3942.  +----------+---------+----------+--------+---------+--------+--------+
  3943.  | Photo-   | 0       | 0, 1     | 0, 1   | 10      | 2, 5,  | 0, 1,  |
  3944.  | metric-  |         |          |        |         | 10     | 2, 5,  |
  3945.  | Interp-  |         |          |        |         |        | 10     |
  3946.  | retation |         |          |        |         |        |        |
  3947.  +----------+---------+----------+--------+---------+--------+--------+
  3948.  | Resolu-  | 2       | 2, 3     | 2, 3   | 2, 3    | 2, 3   | 2, 3   |
  3949.  | tionUnit |         |          |        |         |        |        |
  3950.  +----------+---------+----------+--------+---------+--------+--------+
  3951.  | RowsPer- | n       | n        | n      | n       | n      | n      |
  3952.  | Strip    |         |          |        |         |        |        |
  3953.  +----------+---------+----------+--------+---------+--------+--------+
  3954.  | Samples- | 1       | 1        | 1      | 1, 3    | 1, 3, 4| 1, 3, 4|
  3955.  | PerPixel |         |          |        |         |        |        |
  3956.  +----------+---------+----------+--------+---------+--------+--------+
  3957.  | Software |         | {ASCII}  | {ASCII}| {ASCII} | {ASCII}| {ASCII}|
  3958.  +----------+---------+----------+--------+---------+--------+--------+
  3959.  | Strip-   | n       | <n>      | <n>    | <n>     | <n>    | <n>    |
  3960.  | Byte-    |         |          |        |         |        |        |
  3961.  | Counts   |         |          |        |         |        |        |
  3962.  +----------+---------+----------+--------+---------+--------+--------+
  3963.  | Strip-   | n       | <n>      | <n>    | <n>     | <n>    | <n>    |
  3964.  | Offsets  |         |          |        |         |        |        |
  3965.  +----------+---------+----------+--------+---------+--------+--------+
  3966.  | XResolu- | 204     | 200, 204, 300     |    100, 200, 300, 400     |
  3967.  | tion     | 200     | 400, 408          |                           |
  3968.  +----------+---------+----------+--------+---------+--------+--------+
  3969.  | YResolu- | 98, 196 | 98, 196, 100, 200 |    100, 200, 300, 400     |
  3970.  | tion     | 100,200 | 300, 391, 400     |                           |
  3971.  +----------+---------+----------+--------+---------+--------+--------+
  3972.  
  3973.  
  3974.  
  3975.  
  3976.  
  3977. McIntyre, et. al.           Standards Track                    [Page 71]
  3978.  
  3979. RFC 2301              File Format for Internet Fax            March 1998
  3980.  
  3981.  
  3982. Table A.2  TIFF Extension Fields
  3983.  
  3984.             +---------------------------------------------------------+
  3985.             |                    Fax Mode/Profile                     |
  3986.             +---------------------------------------------------------|
  3987.             | Minimal | Extended |  JBIG  |  Lossy  |Lossless| Mixed  |
  3988.  +----------|   B&W   |    B&W   |  B&W   |  Color  | Color  | Raster |
  3989.  |   TIFF   |         |          |        |         |        | Content|
  3990.  |  Field   |    S    |     F    |   J    |    C    |   L    |   M    |
  3991.  +----------+---------+----------+--------+---------+--------+--------+
  3992.  | Chroma-  |         |          |        | 1       |        | 1      |
  3993.  | Position-|         |          |        |         |        |        |
  3994.  | ing      |         |          |        |         |        |        |
  3995.  +----------+---------+----------+--------+---------+--------+--------+
  3996.  | Chroma-  |         |          |        | <1, 1>  |        | <1, 1> |
  3997.  | SubSampl-|         |          |        | <2, 2>  |        | <2, 2> |
  3998.  | ing      |         |          |        |         |        |        |
  3999.  +----------+---------+----------+--------+---------+--------+--------+
  4000.  | Document-|         | {ASCII}  | {ASCII}| {ASCII} | {ASCII}| {ASCII}|
  4001.  | Name     |         |          |        |         |        |        |
  4002.  +----------+---------+----------+--------+---------+--------+--------+
  4003.  | Indexed  |         |          |        |         | 0,1    | 0,1    |
  4004.  +----------+---------+----------+--------+---------+--------+--------+
  4005.  | Page-    | n, m    | n, m     | n, m   | n, m    | n, m   | n, m   |
  4006.  | Number   |         |          |        |         |        |        |
  4007.  +----------+---------+----------+--------+---------+--------+--------+
  4008.  | SubIFDs  |         |          |        |         |        | <IFD>  |
  4009.  +----------+---------+----------+--------+---------+--------+--------+
  4010.  | T4Options| 0, 4    | 0, 1,    |        |         |        | 0, 1,  |
  4011.  |          |         | 4, 5     |        |         |        | 4, 5   |
  4012.  +----------+---------+----------+--------+---------+--------+--------+
  4013.  | T6Options|         | 0        |        |         |        | 0      |
  4014.  +----------+---------+----------+--------+---------+--------+--------+
  4015.  | XPosition|         |          |        |         |        | r      |
  4016.  +----------+---------+----------+--------+---------+--------+--------+
  4017.  | YPosition|         |          |        |         |        | r      |
  4018.  +----------+---------+----------+--------+---------+--------+--------+
  4019.  
  4020.  
  4021.  
  4022.  
  4023.  
  4024.  
  4025.  
  4026.  
  4027.  
  4028.  
  4029.  
  4030.  
  4031.  
  4032.  
  4033. McIntyre, et. al.           Standards Track                    [Page 72]
  4034.  
  4035. RFC 2301              File Format for Internet Fax            March 1998
  4036.  
  4037.  
  4038. Table A.3   New Fields
  4039.  
  4040.             +---------------------------------------------------------+
  4041.             |                    Fax Mode/Profile                     |
  4042.             +---------------------------------------------------------|
  4043.             | Minimal | Extended |  JBIG  |  Lossy  |Lossless| Mixed  |
  4044.  +----------|   B&W   |    B&W   |  B&W   |  Color  | Color  | Raster |
  4045.  |   TIFF   |         |          |        |         |        | Content|
  4046.  |  Field   |    S    |     F    |   J    |    C    |   L    |   M    |
  4047.  +----------+---------+----------+--------+---------+--------+--------+
  4048.  | BadFax-  |         | n        |        |         |        |        |
  4049.  | Lines    |         |          |        |         |        |        |
  4050.  +----------+---------+----------+--------+---------+--------+--------+
  4051.  | CleanFax-|         | 0, 1, 2  |        |         |        |        |
  4052.  | Data     |         |          |        |         |        |        |
  4053.  +----------+---------+----------+--------+---------+--------+--------+
  4054.  | Coding-  |         |          | n      | n       | n      | n      |
  4055.  | Method   |         |          |        |         |        |        |
  4056.  +----------+---------+----------+--------+---------+--------+--------+
  4057.  | Consecu- |         | n        |        |         |        |        |
  4058.  | tiveBad- |         |          |        |         |        |        |
  4059.  | FaxLines |         |          |        |         |        |        |
  4060.  +----------+---------+----------+--------+---------+--------+--------+
  4061.  | Decode   |         |          |        | <r>     | <r>    | <r>    |
  4062.  +----------+---------+----------+--------+---------+--------+--------+
  4063.  | Default- |         |          |        |         |        | <n>    |
  4064.  |ImageColor|         |          |        |         |        |        |
  4065.  +----------+---------+----------+--------+---------+--------+--------+
  4066.  | Fax-     |         |          | n      | n       | n      | n      |
  4067.  | Profile  |         |          |        |         |        |        |
  4068.  +----------+---------+----------+--------+---------+--------+--------+
  4069.  | Global-  |         | IFD      | IFD    | IFD     | IFD    | IFD    |
  4070.  | Parame-  |         |          |        |         |        |        |
  4071.  | tersIFD  |         |          |        |         |        |        |
  4072.  +----------+---------+----------+--------+---------+--------+--------+
  4073.  | Image-   |         |          |        |         |        | n, m   |
  4074.  | Layer    |         |          |        |         |        |        |
  4075.  +----------+---------+----------+--------+---------+--------+--------+
  4076.  | Mode-    |         |          |        |         |        | n      |
  4077.  | Number   |         |          |        |         |        |        |
  4078.  +----------+---------+----------+--------+---------+--------+--------|
  4079.  | Profile- |         |          | n      | n       | n      | n      |
  4080.  | Type     |         |          |        |         |        |        |
  4081.  +--------------------------------------------------------------------+
  4082.  
  4083.  
  4084.  
  4085.  
  4086.  
  4087.  
  4088.  
  4089. McIntyre, et. al.           Standards Track                    [Page 73]
  4090.  
  4091. RFC 2301              File Format for Internet Fax            March 1998
  4092.  
  4093.  
  4094.  +----------+---------+----------+--------+---------+--------+--------+
  4095.  | Strip-   |         |          |        |         |        | <n>    |
  4096.  | RowCounts|         |          |        |         |        |        |
  4097.  +----------+---------+----------+--------+---------+--------+--------+
  4098.  | Version- |         |          |        | <b>     |<b>     |        |
  4099.  | Year     |         |          |        |         |        |        |
  4100.  +----------+---------+----------+--------+---------+--------+--------+
  4101.  
  4102.  
  4103.  
  4104.  
  4105.  
  4106.  
  4107.  
  4108.  
  4109.  
  4110.  
  4111.  
  4112.  
  4113.  
  4114.  
  4115.  
  4116.  
  4117.  
  4118.  
  4119.  
  4120.  
  4121.  
  4122.  
  4123.  
  4124.  
  4125.  
  4126.  
  4127.  
  4128.  
  4129.  
  4130.  
  4131.  
  4132.  
  4133.  
  4134.  
  4135.  
  4136.  
  4137.  
  4138.  
  4139.  
  4140.  
  4141.  
  4142.  
  4143.  
  4144.  
  4145. McIntyre, et. al.           Standards Track                    [Page 74]
  4146.  
  4147. RFC 2301              File Format for Internet Fax            March 1998
  4148.  
  4149.  
  4150. Annex B.  IANA Registration for image/tiff Application Parameter
  4151. Values used for facsimile
  4152.  
  4153.    To: IANA@isi.edu
  4154.  
  4155.    Subject: Registration of new Application parameter values for
  4156.    image/tiff
  4157.  
  4158.    MIME media type name: image/tiff
  4159.  
  4160.    Optional parameters: Application
  4161.  
  4162.    New Value(s): faxbw, faxcolor
  4163.  
  4164.    Description of Use:
  4165.  
  4166.    faxbw - The "faxbw" application parameter is suitable for use by
  4167.    applications that can process one or more TIFF for facsimile profiles
  4168.    or subsets used for the encoding of black-and-white facsimile data.
  4169.    The definition of the use of this value is contained in Section 9 of
  4170.    this document (TIFFPLUS).
  4171.  
  4172.    Faxcolor - The "faxcolor" application parameter is suitable for use
  4173.    by applications that can process one or more TIFF for facsimile
  4174.    profiles or subsets that can be used for the encoding of black and
  4175.    white, AND color facsimile data. The definition of the use of this
  4176.    value is contained in Section 9 of this document (TIFFPLUS).
  4177.  
  4178.  
  4179.  
  4180.  
  4181.  
  4182.  
  4183.  
  4184.  
  4185.  
  4186.  
  4187.  
  4188.  
  4189.  
  4190.  
  4191.  
  4192.  
  4193.  
  4194.  
  4195.  
  4196.  
  4197.  
  4198.  
  4199.  
  4200.  
  4201. McIntyre, et. al.           Standards Track                    [Page 75]
  4202.  
  4203. RFC 2301              File Format for Internet Fax            March 1998
  4204.  
  4205.  
  4206. Security Considerations:
  4207.  
  4208.    Security considerations related to use of the TIFF subsets described
  4209.    by the "faxbw" and "faxcolor" values of the Application parameter are
  4210.    identified in Section 10 of this document (TIFFPLUS).
  4211.  
  4212. Persons & email addresses to contact for further information:
  4213.  
  4214.    Glenn W. Parsons (Glenn.Parsons@Nortel.ca)
  4215.    James Rafferty (Jrafferty@worldnet.att.net)
  4216.    Stephen Zilles (szilles@adobe.com)
  4217.  
  4218.    Change Controller:  Stephen Zilles
  4219.  
  4220. INFORMATION TO THE SUBMITTER:
  4221.  
  4222.    The accepted registrations will be listed in the "Assigned Numbers"
  4223.    series of RFCs.  The information in the registration form is freely
  4224.    distributable.
  4225.  
  4226.  
  4227.  
  4228.  
  4229.  
  4230.  
  4231.  
  4232.  
  4233.  
  4234.  
  4235.  
  4236.  
  4237.  
  4238.  
  4239.  
  4240.  
  4241.  
  4242.  
  4243.  
  4244.  
  4245.  
  4246.  
  4247.  
  4248.  
  4249.  
  4250.  
  4251.  
  4252.  
  4253.  
  4254.  
  4255.  
  4256.  
  4257. McIntyre, et. al.           Standards Track                    [Page 76]
  4258.  
  4259. RFC 2301              File Format for Internet Fax            March 1998
  4260.  
  4261.  
  4262. Full Copyright Statement
  4263.  
  4264.    Copyright (C) The Internet Society (1998).  All Rights Reserved.
  4265.  
  4266.    This document and translations of it may be copied and furnished to
  4267.    others, and derivative works that comment on or otherwise explain it
  4268.    or assist in its implementation may be prepared, copied, published
  4269.    and distributed, in whole or in part, without restriction of any
  4270.    kind, provided that the above copyright notice and this paragraph are
  4271.    included on all such copies and derivative works.  However, this
  4272.    document itself may not be modified in any way, such as by removing
  4273.    the copyright notice or references to the Internet Society or other
  4274.    Internet organizations, except as needed for the purpose of
  4275.    developing Internet standards in which case the procedures for
  4276.    copyrights defined in the Internet Standards process must be
  4277.    followed, or as required to translate it into languages other than
  4278.    English.
  4279.  
  4280.    The limited permissions granted above are perpetual and will not be
  4281.    revoked by the Internet Society or its successors or assigns.
  4282.  
  4283.    This document and the information contained herein is provided on an
  4284.    "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING
  4285.    TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
  4286.    BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
  4287.    HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF
  4288.    MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
  4289.  
  4290.  
  4291.  
  4292.  
  4293.  
  4294.  
  4295.  
  4296.  
  4297.  
  4298.  
  4299.  
  4300.  
  4301.  
  4302.  
  4303.  
  4304.  
  4305.  
  4306.  
  4307.  
  4308.  
  4309.  
  4310.  
  4311.  
  4312.  
  4313. McIntyre, et. al.           Standards Track                    [Page 77]
  4314.  
  4315.