    001/*
    002 * Licensed to the Apache Software Foundation (ASF) under one or more
    003 * contributor license agreements.  See the NOTICE file distributed with
    004 * this work for additional information regarding copyright ownership.
    005 * The ASF licenses this file to You under the Apache License, Version 2.0
    006 * (the "License"); you may not use this file except in compliance with
    007 * the License.  You may obtain a copy of the License at
    008 *
    009 *      http://www.apache.org/licenses/LICENSE-2.0
    010 *
    011 * Unless required by applicable law or agreed to in writing, software
    012 * distributed under the License is distributed on an "AS IS" BASIS,
    013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    014 * See the License for the specific language governing permissions and
    015 * limitations under the License.
    016 */
    017package org.apache.commons.imaging.formats.tiff.constants;
    018
    019import java.util.Arrays;
    020import java.util.Collections;
    021import java.util.List;
    022
    023import org.apache.commons.imaging.formats.tiff.taginfos.TagInfo;
    024import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoAny;
    025import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoAscii;
    026import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoByteOrShort;
    027import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoBytes;
    028import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoLong;
    029import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoLongs;
    030import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoRational;
    031import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoRationals;
    032import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoShort;
    033import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoShortOrLong;
    034import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoShorts;
    035import org.apache.commons.imaging.formats.tiff.taginfos.TagInfoUnknowns;
    036
    037/**
    038 * Tags from the TIFF6 specification.
    039 * <p>
    040 * [BROKEN URL] http://partners.adobe.com/public/developer/en/tiff/TIFF6.pdf
    041 * </p>
    042 */
    043public final class TiffTagConstants {
    044
    045    public static final TagInfoLong TIFF_TAG_NEW_SUBFILE_TYPE = new TagInfoLong("NewSubfileType", 0xFE, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    046    public static final int SUBFILE_TYPE_VALUE_FULL_RESOLUTION_IMAGE = 0;
    047    public static final int SUBFILE_TYPE_VALUE_REDUCED_RESOLUTION_IMAGE = 1;
    048    public static final int SUBFILE_TYPE_VALUE_SINGLE_PAGE_OF_MULTI_PAGE_IMAGE = 2;
    049    public static final int SUBFILE_TYPE_VALUE_SINGLE_PAGE_OF_MULTI_PAGE_REDUCED_RESOLUTION_IMAGE = 3;
    050    public static final int SUBFILE_TYPE_VALUE_TRANSPARENCY_MASK = 4;
    051    public static final int SUBFILE_TYPE_VALUE_TRANSPARENCY_MASK_OF_REDUCED_RESOLUTION_IMAGE = 5;
    052    public static final int SUBFILE_TYPE_VALUE_TRANSPARENCY_MASK_OF_MULTI_PAGE_IMAGE = 6;
    053    public static final int SUBFILE_TYPE_VALUE_TRANSPARENCY_MASK_OF_REDUCED_RESOLUTION_MULTI_PAGE_IMAGE = 7;
    054
    055    public static final TagInfoShort TIFF_TAG_SUBFILE_TYPE = new TagInfoShort("SubfileType", 0xFF, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    056    public static final int OLD_SUBFILE_TYPE_VALUE_FULL_RESOLUTION_IMAGE = 1;
    057    public static final int OLD_SUBFILE_TYPE_VALUE_REDUCED_RESOLUTION_IMAGE = 2;
    058    public static final int OLD_SUBFILE_TYPE_VALUE_SINGLE_PAGE_OF_MULTI_PAGE_IMAGE = 3;
    059
    060    public static final TagInfoShortOrLong TIFF_TAG_IMAGE_WIDTH = new TagInfoShortOrLong("ImageWidth", 0x100, 1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    061
    062    public static final TagInfoShortOrLong TIFF_TAG_IMAGE_LENGTH = new TagInfoShortOrLong("ImageLength", 0x101, 1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    063
    064    public static final TagInfoShorts TIFF_TAG_BITS_PER_SAMPLE = new TagInfoShorts("BitsPerSample", 0x102, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    065
    066    public static final TagInfoShort TIFF_TAG_COMPRESSION = new TagInfoShort("Compression", 0x103, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    067    public static final int COMPRESSION_VALUE_UNCOMPRESSED = 1;
    068    public static final int COMPRESSION_VALUE_CCITT_1D = 2;
    069    public static final int COMPRESSION_VALUE_T4_GROUP_3_FAX = 3;
    070    public static final int COMPRESSION_VALUE_T6_GROUP_4_FAX = 4;
    071    public static final int COMPRESSION_VALUE_LZW = 5;
    072    public static final int COMPRESSION_VALUE_JPEG_OLD_STYLE = 6;
    073    public static final int COMPRESSION_VALUE_JPEG = 7;
    074    public static final int COMPRESSION_VALUE_ADOBE_DEFLATE = 8;
    075    public static final int COMPRESSION_VALUE_JBIG_B_AND_W = 9;
    076    public static final int COMPRESSION_VALUE_JBIG_COLOR = 10;
    077    public static final int COMPRESSION_VALUE_NEXT = 32766;
    078    public static final int COMPRESSION_VALUE_EPSON_ERF_COMPRESSED = 32769;
    079    public static final int COMPRESSION_VALUE_CCIRLEW = 32771;
    080    public static final int COMPRESSION_VALUE_PACK_BITS = 32773;
    081    public static final int COMPRESSION_VALUE_THUNDERSCAN = 32809;
    082    public static final int COMPRESSION_VALUE_IT8CTPAD = 32895;
    083    public static final int COMPRESSION_VALUE_IT8LW = 32896;
    084    public static final int COMPRESSION_VALUE_IT8MP = 32897;
    085    public static final int COMPRESSION_VALUE_IT8BL = 32898;
    086    public static final int COMPRESSION_VALUE_PIXAR_FILM = 32908;
    087    public static final int COMPRESSION_VALUE_PIXAR_LOG = 32909;
    088    public static final int COMPRESSION_VALUE_DEFLATE = 32946;
    089    public static final int COMPRESSION_VALUE_DCS = 32947;
    090    public static final int COMPRESSION_VALUE_JBIG = 34661;
    091    public static final int COMPRESSION_VALUE_SGILOG = 34676;
    092    public static final int COMPRESSION_VALUE_SGILOG_24 = 34677;
    093    public static final int COMPRESSION_VALUE_JPEG_2000 = 34712;
    094    public static final int COMPRESSION_VALUE_NIKON_NEF_COMPRESSED = 34713;
    095    public static final int COMPRESSION_VALUE_KODAK_DCR_COMPRESSED = 65000;
    096    public static final int COMPRESSION_VALUE_PENTAX_PEF_COMPRESSED = 65535;
    097
    098    public static final TagInfoShort TIFF_TAG_PHOTOMETRIC_INTERPRETATION = new TagInfoShort("PhotometricInterpretation", 0x106,
    099            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    100    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_WHITE_IS_ZERO = 0;
    101    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_BLACK_IS_ZERO = 1;
    102    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_RGB = 2;
    103    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_RGB_PALETTE = 3;
    104    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_TRANSPARENCY_MASK = 4;
    105    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_CMYK = 5;
    106    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_YCB_CR = 6;
    107    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_CIELAB = 8;
    108    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_ICCLAB = 9;
    109    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_ITULAB = 10;
    110    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_COLOR_FILTER_ARRAY = 32803;
    111    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_PIXAR_LOG_L = 32844;
    112    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_PIXAR_LOG_LUV = 32845;
    113    public static final int PHOTOMETRIC_INTERPRETATION_VALUE_LINEAR_RAW = 34892;
    114
    115    public static final TagInfoShort TIFF_TAG_THRESHHOLDING = new TagInfoShort("Threshholding", 0x107, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    116    public static final int THRESHOLDING_VALUE_NO_DITHERING_OR_HALFTONING = 1;
    117    public static final int THRESHOLDING_VALUE_ORDERED_DITHER_OR_HALFTONE = 2;
    118    public static final int THRESHOLDING_VALUE_RANDOMIZED_DITHER = 3;
    119
    120    public static final TagInfoShort TIFF_TAG_CELL_WIDTH = new TagInfoShort("CellWidth", 0x108, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    121
    122    public static final TagInfoShort TIFF_TAG_CELL_LENGTH = new TagInfoShort("CellLength", 0x109, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    123
    124    public static final TagInfoShort TIFF_TAG_FILL_ORDER = new TagInfoShort("FillOrder", 0x10A, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    125    public static final int FILL_ORDER_VALUE_NORMAL = 1;
    126    public static final int FILL_ORDER_VALUE_REVERSED = 2;
    127
    128    public static final TagInfoAscii TIFF_TAG_DOCUMENT_NAME = new TagInfoAscii("DocumentName", 0x10D, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    129
    130    public static final TagInfoAscii TIFF_TAG_IMAGE_DESCRIPTION = new TagInfoAscii("ImageDescription", 0x10E, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    131
    132    public static final TagInfoAscii TIFF_TAG_MAKE = new TagInfoAscii("Make", 0x10F, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    133
    134    public static final TagInfoAscii TIFF_TAG_MODEL = new TagInfoAscii("Model", 0x110, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    135
    136    public static final TagInfoShortOrLong TIFF_TAG_STRIP_OFFSETS = new TagInfoShortOrLong("StripOffsets", 0x111, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT,
    137            true);
    138
    139    public static final TagInfoShort TIFF_TAG_ORIENTATION = new TagInfoShort("Orientation", 0x112, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    140    public static final int ORIENTATION_VALUE_HORIZONTAL_NORMAL = 1;
    141    public static final int ORIENTATION_VALUE_MIRROR_HORIZONTAL = 2;
    142    public static final int ORIENTATION_VALUE_ROTATE_180 = 3;
    143    public static final int ORIENTATION_VALUE_MIRROR_VERTICAL = 4;
    144    public static final int ORIENTATION_VALUE_MIRROR_HORIZONTAL_AND_ROTATE_270_CW = 5;
    145    public static final int ORIENTATION_VALUE_ROTATE_90_CW = 6;
    146    public static final int ORIENTATION_VALUE_MIRROR_HORIZONTAL_AND_ROTATE_90_CW = 7;
    147    public static final int ORIENTATION_VALUE_ROTATE_270_CW = 8;
    148
    149    public static final TagInfoShort TIFF_TAG_SAMPLES_PER_PIXEL = new TagInfoShort("SamplesPerPixel", 0x115, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    150
    151    public static final TagInfoShortOrLong TIFF_TAG_ROWS_PER_STRIP = new TagInfoShortOrLong("RowsPerStrip", 0x116, 1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    152
    153    public static final TagInfoShortOrLong TIFF_TAG_STRIP_BYTE_COUNTS = new TagInfoShortOrLong("StripByteCounts", 0x117, -1,
    154            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    155
    156    public static final TagInfoShorts TIFF_TAG_MIN_SAMPLE_VALUE = new TagInfoShorts("MinSampleValue", 0x118, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    157
    158    public static final TagInfoShorts TIFF_TAG_MAX_SAMPLE_VALUE = new TagInfoShorts("MaxSampleValue", 0x119, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    159
    160    public static final TagInfoRational TIFF_TAG_XRESOLUTION = new TagInfoRational("XResolution", 0x11A, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    161
    162    public static final TagInfoRational TIFF_TAG_YRESOLUTION = new TagInfoRational("YResolution", 0x11B, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    163
    164    public static final TagInfoShort TIFF_TAG_PLANAR_CONFIGURATION = new TagInfoShort("PlanarConfiguration", 0x11C, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    165    public static final int PLANAR_CONFIGURATION_VALUE_CHUNKY = 1;
    166    public static final int PLANAR_CONFIGURATION_VALUE_PLANAR = 2;
    167
    168    public static final TagInfoAscii TIFF_TAG_PAGE_NAME = new TagInfoAscii("PageName", 0x11D, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    169
    170    public static final TagInfoRationals TIFF_TAG_XPOSITION = new TagInfoRationals("XPosition", 0x11E, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    171
    172    public static final TagInfoRationals TIFF_TAG_YPOSITION = new TagInfoRationals("YPosition", 0x11F, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    173
    174    public static final TagInfoLongs TIFF_TAG_FREE_OFFSETS = new TagInfoLongs("FreeOffsets", 0x120, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    175
    176    public static final TagInfoLongs TIFF_TAG_FREE_BYTE_COUNTS = new TagInfoLongs("FreeByteCounts", 0x121, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    177
    178    public static final TagInfoShort TIFF_TAG_GRAY_RESPONSE_UNIT = new TagInfoShort("GrayResponseUnit", 0x122, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    179    public static final int GRAY_RESPONSE_UNIT_VALUE_0_1 = 1;
    180    public static final int GRAY_RESPONSE_UNIT_VALUE_0_01 = 2;
    181    public static final int GRAY_RESPONSE_UNIT_VALUE_0_001 = 3;
    182    public static final int GRAY_RESPONSE_UNIT_VALUE_0_0001 = 4;
    183    public static final int GRAY_RESPONSE_UNIT_VALUE_0_00001 = 5;
    184
    185    public static final TagInfoShorts TIFF_TAG_GRAY_RESPONSE_CURVE = new TagInfoShorts("GrayResponseCurve", 0x123, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    186
    187    public static final TagInfoLong TIFF_TAG_T4_OPTIONS = new TagInfoLong("T4Options", 0x124, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    188
    189    public static final TagInfoLong TIFF_TAG_T6_OPTIONS = new TagInfoLong("T6Options", 0x125, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    190
    191    public static final TagInfoShort TIFF_TAG_RESOLUTION_UNIT = new TagInfoShort("ResolutionUnit", 0x128, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    192    public static final int RESOLUTION_UNIT_VALUE_NONE = 1;
    193    public static final int RESOLUTION_UNIT_VALUE_INCHES = 2;
    194    public static final int RESOLUTION_UNIT_VALUE_CM = 3;
    195
    196    public static final TagInfoShorts TIFF_TAG_PAGE_NUMBER = new TagInfoShorts("PageNumber", 0x129, 2, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    197
    198    public static final TagInfoShorts TIFF_TAG_TRANSFER_FUNCTION = new TagInfoShorts("TransferFunction", 0x12D, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    199
    200    public static final TagInfoAscii TIFF_TAG_SOFTWARE = new TagInfoAscii("Software", 0x131, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    201
    202    public static final TagInfoAscii TIFF_TAG_DATE_TIME = new TagInfoAscii("DateTime", 0x132, 20, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    203
    204    public static final TagInfoAscii TIFF_TAG_ARTIST = new TagInfoAscii("Artist", 0x13B, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    205
    206    public static final TagInfoAscii TIFF_TAG_HOST_COMPUTER = new TagInfoAscii("HostComputer", 0x13C, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    207
    208    public static final TagInfoShort TIFF_TAG_PREDICTOR = new TagInfoShort("Predictor", 0x13D, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    209    public static final int PREDICTOR_VALUE_NONE = 1;
    210    public static final int PREDICTOR_VALUE_HORIZONTAL_DIFFERENCING = 2;
    211    public static final int PREDICTOR_VALUE_FLOATING_POINT_DIFFERENCING = 3;
    212
    213    public static final TagInfoRationals TIFF_TAG_WHITE_POINT = new TagInfoRationals("WhitePoint", 0x13E, 2, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    214
    215    public static final TagInfoRationals TIFF_TAG_PRIMARY_CHROMATICITIES = new TagInfoRationals("PrimaryChromaticities", 0x13F, 6,
    216            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    217
    218    public static final TagInfoShorts TIFF_TAG_COLOR_MAP = new TagInfoShorts("ColorMap", 0x140, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    219
    220    public static final TagInfoShorts TIFF_TAG_HALFTONE_HINTS = new TagInfoShorts("HalftoneHints", 0x141, 2, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    221
    222    public static final TagInfoShortOrLong TIFF_TAG_TILE_WIDTH = new TagInfoShortOrLong("TileWidth", 0x142, 1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    223
    224    public static final TagInfoShortOrLong TIFF_TAG_TILE_LENGTH = new TagInfoShortOrLong("TileLength", 0x143, 1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    225
    226    public static final TagInfoLongs TIFF_TAG_TILE_OFFSETS = new TagInfoLongs("TileOffsets", 0x144, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT, true);
    227
    228    public static final TagInfoShortOrLong TIFF_TAG_TILE_BYTE_COUNTS = new TagInfoShortOrLong("TileByteCounts", 0x145, -1,
    229            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    230
    231    public static final TagInfoShort TIFF_TAG_INK_SET = new TagInfoShort("InkSet", 0x14C, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    232    public static final int INK_SET_VALUE_CMYK = 1;
    233    public static final int INK_SET_VALUE_NOT_CMYK = 2;
    234
    235    public static final TagInfoAscii TIFF_TAG_INK_NAMES = new TagInfoAscii("InkNames", 0x14D, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    236
    237    public static final TagInfoShort TIFF_TAG_NUMBER_OF_INKS = new TagInfoShort("NumberOfInks", 0x14E, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    238
    239    public static final TagInfoByteOrShort TIFF_TAG_DOT_RANGE = new TagInfoByteOrShort("DotRange", 0x150, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    240
    241    public static final TagInfoAscii TIFF_TAG_TARGET_PRINTER = new TagInfoAscii("TargetPrinter", 0x151, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    242
    243    public static final TagInfoShorts TIFF_TAG_EXTRA_SAMPLES = new TagInfoShorts("ExtraSamples", 0x152, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    244    public static final int EXTRA_SAMPLE_ASSOCIATED_ALPHA = 1;
    245    public static final int EXTRA_SAMPLE_UNASSOCIATED_ALPHA = 2;
    246
    247    public static final TagInfoShorts TIFF_TAG_SAMPLE_FORMAT = new TagInfoShorts("SampleFormat", 0x153, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    248    public static final int SAMPLE_FORMAT_VALUE_UNSIGNED_INTEGER = 1;
    249    public static final int SAMPLE_FORMAT_VALUE_TWOS_COMPLEMENT_SIGNED_INTEGER = 2;
    250    public static final int SAMPLE_FORMAT_VALUE_IEEE_FLOATING_POINT = 3;
    251    public static final int SAMPLE_FORMAT_VALUE_UNDEFINED = 4;
    252    public static final int SAMPLE_FORMAT_VALUE_COMPLEX_INTEGER = 5;
    253    public static final int SAMPLE_FORMAT_VALUE_IEEE_COMPLEX_FLOAT = 6;
    254
    255    public static final TagInfoAny TIFF_TAG_SMIN_SAMPLE_VALUE = new TagInfoAny("SMinSampleValue", 0x154, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    256
    257    public static final TagInfoAny TIFF_TAG_SMAX_SAMPLE_VALUE = new TagInfoAny("SMaxSampleValue", 0x155, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    258
    259    public static final TagInfoShorts TIFF_TAG_TRANSFER_RANGE = new TagInfoShorts("TransferRange", 0x156, 6, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    260
    261    public static final TagInfoShort TIFF_TAG_JPEG_PROC = new TagInfoShort("JPEGProc", 0x200, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    262    public static final int JPEGPROC_VALUE_BASELINE = 1;
    263    public static final int JPEGPROC_VALUE_LOSSLESS = 14;
    264
    265    public static final TagInfoLong TIFF_TAG_JPEG_INTERCHANGE_FORMAT = new TagInfoLong("JPEGInterchangeFormat", 0x201, TiffDirectoryType.TIFF_DIRECTORY_ROOT,
    266            true);
    267
    268    public static final TagInfoLong TIFF_TAG_JPEG_INTERCHANGE_FORMAT_LENGTH = new TagInfoLong("JPEGInterchangeFormatLength", 0x202,
    269            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    270
    271    public static final TagInfoShort TIFF_TAG_JPEG_RESTART_INTERVAL = new TagInfoShort("JPEGRestartInterval", 0x203, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    272
    273    public static final TagInfoShorts TIFF_TAG_JPEG_LOSSLESS_PREDICTORS = new TagInfoShorts("JPEGLosslessPredictors", 0x205, -1,
    274            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    275
    276    public static final TagInfoShorts TIFF_TAG_JPEG_POINT_TRANSFORMS = new TagInfoShorts("JPEGPointTransforms", 0x206, -1,
    277            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    278
    279    public static final TagInfoLongs TIFF_TAG_JPEG_QTABLES = new TagInfoLongs("JPEGQTables", 0x207, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    280
    281    public static final TagInfoLongs TIFF_TAG_JPEG_DCTABLES = new TagInfoLongs("JPEGDCTables", 0x208, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    282
    283    public static final TagInfoLongs TIFF_TAG_JPEG_ACTABLES = new TagInfoLongs("JPEGACTables", 0x209, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    284
    285    public static final TagInfoRationals TIFF_TAG_YCBCR_COEFFICIENTS = new TagInfoRationals("YCbCrCoefficients", 0x211, 3,
    286            TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    287
    288    public static final TagInfoShorts TIFF_TAG_YCBCR_SUB_SAMPLING = new TagInfoShorts("YCbCrSubSampling", 0x212, 2, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    289
    290    public static final TagInfoShort TIFF_TAG_YCBCR_POSITIONING = new TagInfoShort("YCbCrPositioning", 0x213, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    291    public static final int YCB_CR_POSITIONING_VALUE_CENTERED = 1;
    292    public static final int YCB_CR_POSITIONING_VALUE_CO_SITED = 2;
    293
    294    public static final TagInfoLongs TIFF_TAG_REFERENCE_BLACK_WHITE = new TagInfoLongs("ReferenceBlackWhite", 0x214, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    295
    296    public static final TagInfoAscii TIFF_TAG_COPYRIGHT = new TagInfoAscii("Copyright", 0x8298, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    297
    298    public static final TagInfoBytes TIFF_TAG_XMP = new TagInfoBytes("XMP", 0x2BC, -1, TiffDirectoryType.TIFF_DIRECTORY_ROOT);
    299
    300    // TODO:
    301    // public static final TagInfo2 TIFF_TAG_UNKNOWN = null;
    302    public static final TagInfoUnknowns TIFF_TAG_UNKNOWN = new TagInfoUnknowns("Unknown Tag", -1, TagInfo.LENGTH_UNKNOWN,
    303            TiffDirectoryType.EXIF_DIRECTORY_UNKNOWN);
    304
    305    public static final List<TagInfo> ALL_TIFF_TAGS = Collections.unmodifiableList(Arrays.asList(TIFF_TAG_NEW_SUBFILE_TYPE, TIFF_TAG_SUBFILE_TYPE,
    306            TIFF_TAG_IMAGE_WIDTH, TIFF_TAG_IMAGE_LENGTH, TIFF_TAG_BITS_PER_SAMPLE, TIFF_TAG_COMPRESSION, TIFF_TAG_PHOTOMETRIC_INTERPRETATION,
    307            TIFF_TAG_THRESHHOLDING, TIFF_TAG_CELL_WIDTH, TIFF_TAG_CELL_LENGTH, TIFF_TAG_FILL_ORDER, TIFF_TAG_DOCUMENT_NAME, TIFF_TAG_IMAGE_DESCRIPTION,
    308            TIFF_TAG_MAKE, TIFF_TAG_MODEL, TIFF_TAG_STRIP_OFFSETS, TIFF_TAG_ORIENTATION, TIFF_TAG_SAMPLES_PER_PIXEL, TIFF_TAG_ROWS_PER_STRIP,
    309            TIFF_TAG_STRIP_BYTE_COUNTS, TIFF_TAG_MIN_SAMPLE_VALUE, TIFF_TAG_MAX_SAMPLE_VALUE, TIFF_TAG_XRESOLUTION, TIFF_TAG_YRESOLUTION,
    310            TIFF_TAG_PLANAR_CONFIGURATION, TIFF_TAG_PAGE_NAME, TIFF_TAG_XPOSITION, TIFF_TAG_YPOSITION, TIFF_TAG_FREE_OFFSETS, TIFF_TAG_FREE_BYTE_COUNTS,
    311            TIFF_TAG_GRAY_RESPONSE_UNIT, TIFF_TAG_GRAY_RESPONSE_CURVE, TIFF_TAG_T4_OPTIONS, TIFF_TAG_T6_OPTIONS, TIFF_TAG_RESOLUTION_UNIT, TIFF_TAG_PAGE_NUMBER,
    312            TIFF_TAG_TRANSFER_FUNCTION, TIFF_TAG_SOFTWARE, TIFF_TAG_DATE_TIME, TIFF_TAG_ARTIST, TIFF_TAG_HOST_COMPUTER, TIFF_TAG_PREDICTOR,
    313            TIFF_TAG_WHITE_POINT, TIFF_TAG_PRIMARY_CHROMATICITIES, TIFF_TAG_COLOR_MAP, TIFF_TAG_HALFTONE_HINTS, TIFF_TAG_TILE_WIDTH, TIFF_TAG_TILE_LENGTH,
    314            TIFF_TAG_TILE_OFFSETS, TIFF_TAG_TILE_BYTE_COUNTS, TIFF_TAG_INK_SET, TIFF_TAG_INK_NAMES, TIFF_TAG_NUMBER_OF_INKS, TIFF_TAG_DOT_RANGE,
    315            TIFF_TAG_TARGET_PRINTER, TIFF_TAG_EXTRA_SAMPLES, TIFF_TAG_SAMPLE_FORMAT, TIFF_TAG_SMIN_SAMPLE_VALUE, TIFF_TAG_SMAX_SAMPLE_VALUE,
    316            TIFF_TAG_TRANSFER_RANGE, TIFF_TAG_JPEG_PROC, TIFF_TAG_JPEG_INTERCHANGE_FORMAT, TIFF_TAG_JPEG_INTERCHANGE_FORMAT_LENGTH,
    317            TIFF_TAG_JPEG_RESTART_INTERVAL, TIFF_TAG_JPEG_LOSSLESS_PREDICTORS, TIFF_TAG_JPEG_POINT_TRANSFORMS, TIFF_TAG_JPEG_QTABLES, TIFF_TAG_JPEG_DCTABLES,
    318            TIFF_TAG_JPEG_ACTABLES, TIFF_TAG_YCBCR_COEFFICIENTS, TIFF_TAG_YCBCR_SUB_SAMPLING, TIFF_TAG_YCBCR_POSITIONING, TIFF_TAG_REFERENCE_BLACK_WHITE,
    319            TIFF_TAG_COPYRIGHT, TIFF_TAG_XMP));
    320
    321    private TiffTagConstants() {
    322    }
    323}