1 /* 2 * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 package javax.imageio.plugins.tiff; 26 27 import java.util.ArrayList; 28 import java.util.List; 29 30 /** 31 * A class representing the set of tags found in the baseline TIFF 32 * specification as well as some common additional tags. 33 * 34 * <p> The non-baseline tags included in this class are: 35 * <ul> 36 * <li> {@link #TAG_JPEG_TABLES JPEGTables} 37 * <li> {@link #TAG_ICC_PROFILE ICC Profile} 38 * </ul> 39 * 40 * <p> The non-baseline values of baseline tags included in this class are 41 * <ul> 42 * <li>{@link #TAG_COMPRESSION Compression} tag values: 43 * <ul> 44 * <li>{@link #COMPRESSION_JPEG JPEG-in-TIFF compression}</li> 45 * <li>{@link #COMPRESSION_ZLIB Zlib-in-TIFF compression}</li> 46 * <li>{@link #COMPRESSION_DEFLATE Deflate compression}</li> 47 * </ul> 48 * </li> 49 * <li>{@link #TAG_PHOTOMETRIC_INTERPRETATION PhotometricInterpretation} 50 * tag values: 51 * <ul> 52 * <li>{@link #PHOTOMETRIC_INTERPRETATION_ICCLAB ICCLAB 53 * photometric interpretation}</li> 54 * </ul> 55 * </li> 56 * </ul> 57 * 58 * @since 9 59 * @see <a href="https://www.itu.int/itudoc/itu-t/com16/tiff-fx/docs/tiff6.pdf"> TIFF 6.0 Specification</a> 60 */ 61 public final class BaselineTIFFTagSet extends TIFFTagSet { 62 63 private static BaselineTIFFTagSet theInstance = null; 64 65 // Tags from TIFF 6.0 specification 66 67 /** 68 * Constant specifying the "NewSubfileType" tag. 69 * 70 * @see #NEW_SUBFILE_TYPE_REDUCED_RESOLUTION 71 * @see #NEW_SUBFILE_TYPE_SINGLE_PAGE 72 * @see #NEW_SUBFILE_TYPE_TRANSPARENCY 73 */ 74 public static final int TAG_NEW_SUBFILE_TYPE = 254; 75 76 /** 77 * A mask to be used with the "NewSubfileType" tag. 78 * 79 * @see #TAG_NEW_SUBFILE_TYPE 80 */ 81 public static final int NEW_SUBFILE_TYPE_REDUCED_RESOLUTION = 1; 82 83 /** 84 * A mask to be used with the "NewSubfileType" tag. 85 * 86 * @see #TAG_NEW_SUBFILE_TYPE 87 */ 88 public static final int NEW_SUBFILE_TYPE_SINGLE_PAGE = 2; 89 90 /** 91 * A mask to be used with the "NewSubfileType" tag. 92 * 93 * @see #TAG_NEW_SUBFILE_TYPE 94 */ 95 public static final int NEW_SUBFILE_TYPE_TRANSPARENCY = 4; 96 97 /** 98 * Constant specifying the "SubfileType" tag. 99 * 100 * @see #SUBFILE_TYPE_FULL_RESOLUTION 101 * @see #SUBFILE_TYPE_REDUCED_RESOLUTION 102 * @see #SUBFILE_TYPE_SINGLE_PAGE 103 */ 104 public static final int TAG_SUBFILE_TYPE = 255; 105 106 /** 107 * A value to be used with the "SubfileType" tag. 108 * 109 * @see #TAG_SUBFILE_TYPE 110 */ 111 public static final int SUBFILE_TYPE_FULL_RESOLUTION = 1; 112 113 /** 114 * A value to be used with the "SubfileType" tag. 115 * 116 * @see #TAG_SUBFILE_TYPE 117 */ 118 public static final int SUBFILE_TYPE_REDUCED_RESOLUTION = 2; 119 120 /** 121 * A value to be used with the "SubfileType" tag. 122 * 123 * @see #TAG_SUBFILE_TYPE 124 */ 125 public static final int SUBFILE_TYPE_SINGLE_PAGE = 3; 126 127 /** 128 * Constant specifying the "ImageWidth" tag. 129 */ 130 public static final int TAG_IMAGE_WIDTH = 256; 131 132 /** 133 * Constant specifying the "ImageLength" tag. 134 */ 135 public static final int TAG_IMAGE_LENGTH = 257; 136 137 /** 138 * Constant specifying the "BitsPerSample" tag. 139 */ 140 public static final int TAG_BITS_PER_SAMPLE = 258; 141 142 /** 143 * Constant specifying the "Compression" tag. 144 * 145 * @see #COMPRESSION_NONE 146 * @see #COMPRESSION_CCITT_RLE 147 * @see #COMPRESSION_CCITT_T_4 148 * @see #COMPRESSION_CCITT_T_6 149 * @see #COMPRESSION_LZW 150 * @see #COMPRESSION_OLD_JPEG 151 * @see #COMPRESSION_JPEG 152 * @see #COMPRESSION_ZLIB 153 * @see #COMPRESSION_PACKBITS 154 * @see #COMPRESSION_DEFLATE 155 */ 156 public static final int TAG_COMPRESSION = 259; 157 158 /** 159 * A value to be used with the "Compression" tag. 160 * 161 * @see #TAG_COMPRESSION 162 */ 163 public static final int COMPRESSION_NONE = 1; 164 165 /** 166 * A value to be used with the "Compression" tag. 167 * 168 * @see #TAG_COMPRESSION 169 */ 170 public static final int COMPRESSION_CCITT_RLE = 2; 171 172 /** 173 * A value to be used with the "Compression" tag. 174 * 175 * @see #TAG_COMPRESSION 176 */ 177 public static final int COMPRESSION_CCITT_T_4 = 3; 178 179 /** 180 * A value to be used with the "Compression" tag. 181 * 182 * @see #TAG_COMPRESSION 183 */ 184 public static final int COMPRESSION_CCITT_T_6 = 4; 185 186 /** 187 * A value to be used with the "Compression" tag. 188 * 189 * @see #TAG_COMPRESSION 190 */ 191 public static final int COMPRESSION_LZW = 5; 192 193 /** 194 * A value to be used with the "Compression" tag. 195 * 196 * @see #TAG_COMPRESSION 197 */ 198 public static final int COMPRESSION_OLD_JPEG = 6; 199 200 /** 201 * A value to be used with the "Compression" tag. 202 * 203 * @see #TAG_COMPRESSION 204 */ 205 public static final int COMPRESSION_JPEG = 7; 206 207 /** 208 * A value to be used with the "Compression" tag. 209 * 210 * @see #TAG_COMPRESSION 211 */ 212 public static final int COMPRESSION_ZLIB = 8; 213 214 /** 215 * A value to be used with the "Compression" tag. 216 * 217 * @see #TAG_COMPRESSION 218 */ 219 public static final int COMPRESSION_PACKBITS = 32773; 220 221 /** 222 * A value to be used with the "Compression" tag. 223 * 224 * @see #TAG_COMPRESSION 225 * @see <a href="https://tools.ietf.org/html/rfc1951">DEFLATE specification</a> 226 */ 227 public static final int COMPRESSION_DEFLATE = 32946; 228 229 /** 230 * Constant specifying the "PhotometricInterpretation" tag. 231 * 232 * @see #PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO 233 * @see #PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO 234 * @see #PHOTOMETRIC_INTERPRETATION_RGB 235 * @see #PHOTOMETRIC_INTERPRETATION_PALETTE_COLOR 236 * @see #PHOTOMETRIC_INTERPRETATION_TRANSPARENCY_MASK 237 * @see #PHOTOMETRIC_INTERPRETATION_Y_CB_CR 238 * @see #PHOTOMETRIC_INTERPRETATION_CIELAB 239 * @see #PHOTOMETRIC_INTERPRETATION_ICCLAB 240 */ 241 public static final int TAG_PHOTOMETRIC_INTERPRETATION = 262; 242 243 /** 244 * A value to be used with the "PhotometricInterpretation" tag. 245 * 246 * @see #TAG_PHOTOMETRIC_INTERPRETATION 247 */ 248 public static final int PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO = 0; 249 250 /** 251 * A value to be used with the "PhotometricInterpretation" tag. 252 * 253 * @see #TAG_PHOTOMETRIC_INTERPRETATION 254 */ 255 public static final int PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO = 1; 256 257 /** 258 * A value to be used with the "PhotometricInterpretation" tag. 259 * 260 * @see #TAG_PHOTOMETRIC_INTERPRETATION 261 */ 262 public static final int PHOTOMETRIC_INTERPRETATION_RGB = 2; 263 264 /** 265 * A value to be used with the "PhotometricInterpretation" tag. 266 * 267 * @see #TAG_PHOTOMETRIC_INTERPRETATION 268 */ 269 public static final int PHOTOMETRIC_INTERPRETATION_PALETTE_COLOR = 3; 270 271 /** 272 * A value to be used with the "PhotometricInterpretation" tag. 273 * 274 * @see #TAG_PHOTOMETRIC_INTERPRETATION 275 */ 276 public static final int PHOTOMETRIC_INTERPRETATION_TRANSPARENCY_MASK = 4; 277 278 /** 279 * A value to be used with the "PhotometricInterpretation" tag. 280 * 281 * @see #TAG_PHOTOMETRIC_INTERPRETATION 282 */ 283 public static final int PHOTOMETRIC_INTERPRETATION_CMYK = 5; 284 285 /** 286 * A value to be used with the "PhotometricInterpretation" tag. 287 * 288 * @see #TAG_PHOTOMETRIC_INTERPRETATION 289 */ 290 public static final int PHOTOMETRIC_INTERPRETATION_Y_CB_CR = 6; 291 292 /** 293 * A value to be used with the "PhotometricInterpretation" tag. 294 * 295 * @see #TAG_PHOTOMETRIC_INTERPRETATION 296 */ 297 public static final int PHOTOMETRIC_INTERPRETATION_CIELAB = 8; 298 299 /** 300 * A value to be used with the "PhotometricInterpretation" tag. 301 * 302 * @see #TAG_PHOTOMETRIC_INTERPRETATION 303 */ 304 public static final int PHOTOMETRIC_INTERPRETATION_ICCLAB = 9; 305 306 /** 307 * Constant specifying the "Threshholding" tag. 308 * 309 * @see #THRESHHOLDING_NONE 310 * @see #THRESHHOLDING_ORDERED_DITHER 311 * @see #THRESHHOLDING_RANDOMIZED_DITHER 312 */ 313 public static final int TAG_THRESHHOLDING = 263; 314 315 /** 316 * A value to be used with the "Thresholding" tag. 317 * 318 * @see #TAG_THRESHHOLDING 319 */ 320 public static final int THRESHHOLDING_NONE = 1; 321 322 /** 323 * A value to be used with the "Thresholding" tag. 324 * 325 * @see #TAG_THRESHHOLDING 326 */ 327 public static final int THRESHHOLDING_ORDERED_DITHER = 2; 328 329 /** 330 * A value to be used with the "Thresholding" tag. 331 * 332 * @see #TAG_THRESHHOLDING 333 */ 334 public static final int THRESHHOLDING_RANDOMIZED_DITHER = 3; 335 336 /** 337 * Constant specifying the "Cell_Width" tag. 338 */ 339 public static final int TAG_CELL_WIDTH = 264; 340 341 /** 342 * Constant specifying the "cell_length" tag. 343 */ 344 public static final int TAG_CELL_LENGTH = 265; 345 346 /** 347 * Constant specifying the "fill_order" tag. 348 * 349 * @see #FILL_ORDER_LEFT_TO_RIGHT 350 * @see #FILL_ORDER_RIGHT_TO_LEFT 351 */ 352 public static final int TAG_FILL_ORDER = 266; 353 354 /** 355 * A value to be used with the "FillOrder" tag. 356 * 357 * @see #TAG_FILL_ORDER 358 */ 359 public static final int FILL_ORDER_LEFT_TO_RIGHT = 1; 360 361 /** 362 * A value to be used with the "FillOrder" tag. 363 * 364 * @see #TAG_FILL_ORDER 365 */ 366 public static final int FILL_ORDER_RIGHT_TO_LEFT = 2; 367 368 /** 369 * Constant specifying the "document_name" tag. 370 */ 371 public static final int TAG_DOCUMENT_NAME = 269; 372 373 /** 374 * Constant specifying the "Image_description" tag. 375 */ 376 public static final int TAG_IMAGE_DESCRIPTION = 270; 377 378 /** 379 * Constant specifying the "Make" tag. 380 */ 381 public static final int TAG_MAKE = 271; 382 383 /** 384 * Constant specifying the "Model" tag. 385 */ 386 public static final int TAG_MODEL = 272; 387 388 /** 389 * Constant specifying the "Strip_offsets" tag. 390 */ 391 public static final int TAG_STRIP_OFFSETS = 273; 392 393 /** 394 * Constant specifying the "Orientation" tag. 395 * 396 * @see #ORIENTATION_ROW_0_TOP_COLUMN_0_LEFT 397 * @see #ORIENTATION_ROW_0_TOP_COLUMN_0_RIGHT 398 * @see #ORIENTATION_ROW_0_BOTTOM_COLUMN_0_RIGHT 399 * @see #ORIENTATION_ROW_0_BOTTOM_COLUMN_0_LEFT 400 * @see #ORIENTATION_ROW_0_LEFT_COLUMN_0_TOP 401 * @see #ORIENTATION_ROW_0_RIGHT_COLUMN_0_TOP 402 * @see #ORIENTATION_ROW_0_RIGHT_COLUMN_0_BOTTOM 403 * @see #ORIENTATION_ROW_0_LEFT_COLUMN_0_BOTTOM 404 */ 405 public static final int TAG_ORIENTATION = 274; 406 407 /** 408 * A value to be used with the "Orientation" tag. 409 * 410 * @see #TAG_ORIENTATION 411 */ 412 public static final int ORIENTATION_ROW_0_TOP_COLUMN_0_LEFT = 1; 413 414 /** 415 * A value to be used with the "Orientation" tag. 416 * 417 * @see #TAG_ORIENTATION 418 */ 419 public static final int ORIENTATION_ROW_0_TOP_COLUMN_0_RIGHT = 2; 420 421 /** 422 * A value to be used with the "Orientation" tag. 423 * 424 * @see #TAG_ORIENTATION 425 */ 426 public static final int ORIENTATION_ROW_0_BOTTOM_COLUMN_0_RIGHT = 3; 427 428 /** 429 * A value to be used with the "Orientation" tag. 430 * 431 * @see #TAG_ORIENTATION 432 */ 433 public static final int ORIENTATION_ROW_0_BOTTOM_COLUMN_0_LEFT = 4; 434 435 /** 436 * A value to be used with the "Orientation" tag. 437 * 438 * @see #TAG_ORIENTATION 439 */ 440 public static final int ORIENTATION_ROW_0_LEFT_COLUMN_0_TOP = 5; 441 442 /** 443 * A value to be used with the "Orientation" tag. 444 * 445 * @see #TAG_ORIENTATION 446 */ 447 public static final int ORIENTATION_ROW_0_RIGHT_COLUMN_0_TOP = 6; 448 449 /** 450 * A value to be used with the "Orientation" tag. 451 * 452 * @see #TAG_ORIENTATION 453 */ 454 public static final int ORIENTATION_ROW_0_RIGHT_COLUMN_0_BOTTOM = 7; 455 456 /** 457 * A value to be used with the "Orientation" tag. 458 * 459 * @see #TAG_ORIENTATION 460 */ 461 public static final int ORIENTATION_ROW_0_LEFT_COLUMN_0_BOTTOM = 8; 462 463 /** 464 * Constant specifying the "Samples_per_pixel" tag. 465 */ 466 public static final int TAG_SAMPLES_PER_PIXEL = 277; 467 468 /** 469 * Constant specifying the "Rows_per_strip" tag. 470 */ 471 public static final int TAG_ROWS_PER_STRIP = 278; 472 473 /** 474 * Constant specifying the "Strip_byte_counts" tag. 475 */ 476 public static final int TAG_STRIP_BYTE_COUNTS = 279; 477 478 /** 479 * Constant specifying the "Min_sample_value" tag. 480 */ 481 public static final int TAG_MIN_SAMPLE_VALUE = 280; 482 483 /** 484 * Constant specifying the "Max_sample_value" tag. 485 */ 486 public static final int TAG_MAX_SAMPLE_VALUE = 281; 487 488 /** 489 * Constant specifying the "XResolution" tag. 490 */ 491 public static final int TAG_X_RESOLUTION = 282; 492 493 /** 494 * Constant specifying the "YResolution" tag. 495 */ 496 public static final int TAG_Y_RESOLUTION = 283; 497 498 /** 499 * Constant specifying the "PlanarConfiguration" tag. 500 * 501 * @see #PLANAR_CONFIGURATION_CHUNKY 502 * @see #PLANAR_CONFIGURATION_PLANAR 503 */ 504 public static final int TAG_PLANAR_CONFIGURATION = 284; 505 506 /** 507 * A value to be used with the "PlanarConfiguration" tag. 508 * 509 * @see #TAG_PLANAR_CONFIGURATION 510 */ 511 public static final int PLANAR_CONFIGURATION_CHUNKY = 1; 512 513 /** 514 * A value to be used with the "PlanarConfiguration" tag. 515 * 516 * @see #TAG_PLANAR_CONFIGURATION 517 */ 518 public static final int PLANAR_CONFIGURATION_PLANAR = 2; 519 520 /** 521 * Constant specifying the "PageName" tag. 522 */ 523 public static final int TAG_PAGE_NAME = 285; 524 525 /** 526 * Constant specifying the "XPosition" tag. 527 */ 528 public static final int TAG_X_POSITION = 286; 529 530 /** 531 * Constant specifying the "YPosition" tag. 532 */ 533 public static final int TAG_Y_POSITION = 287; 534 535 /** 536 * Constant specifying the "FreeOffsets" tag. 537 */ 538 public static final int TAG_FREE_OFFSETS = 288; 539 540 /** 541 * Constant specifying the "FreeByteCounts" tag. 542 */ 543 public static final int TAG_FREE_BYTE_COUNTS = 289; 544 545 /** 546 * Constant specifying the "GrayResponseUnit" tag. 547 * 548 * @see #GRAY_RESPONSE_UNIT_TENTHS 549 * @see #GRAY_RESPONSE_UNIT_HUNDREDTHS 550 * @see #GRAY_RESPONSE_UNIT_THOUSANDTHS 551 * @see #GRAY_RESPONSE_UNIT_TEN_THOUSANDTHS 552 * @see #GRAY_RESPONSE_UNIT_HUNDRED_THOUSANDTHS 553 */ 554 public static final int TAG_GRAY_RESPONSE_UNIT = 290; 555 556 /** 557 * A value to be used with the "GrayResponseUnit" tag. 558 * 559 * @see #TAG_GRAY_RESPONSE_UNIT 560 */ 561 public static final int GRAY_RESPONSE_UNIT_TENTHS = 1; 562 563 /** 564 * A value to be used with the "GrayResponseUnit" tag. 565 * 566 * @see #TAG_GRAY_RESPONSE_UNIT 567 */ 568 public static final int GRAY_RESPONSE_UNIT_HUNDREDTHS = 2; 569 570 /** 571 * A value to be used with the "GrayResponseUnit" tag. 572 * 573 * @see #TAG_GRAY_RESPONSE_UNIT 574 */ 575 public static final int GRAY_RESPONSE_UNIT_THOUSANDTHS = 3; 576 577 /** 578 * A value to be used with the "GrayResponseUnit" tag. 579 * 580 * @see #TAG_GRAY_RESPONSE_UNIT 581 */ 582 public static final int GRAY_RESPONSE_UNIT_TEN_THOUSANDTHS = 4; 583 584 /** 585 * A value to be used with the "GrayResponseUnit" tag. 586 * 587 * @see #TAG_GRAY_RESPONSE_UNIT 588 */ 589 public static final int GRAY_RESPONSE_UNIT_HUNDRED_THOUSANDTHS = 5; 590 591 /** 592 * Constant specifying the "GrayResponseCurve" tag. 593 */ 594 public static final int TAG_GRAY_RESPONSE_CURVE = 291; 595 596 /** 597 * Constant specifying the "T4Options" tag. 598 * 599 * @see #T4_OPTIONS_2D_CODING 600 * @see #T4_OPTIONS_UNCOMPRESSED 601 * @see #T4_OPTIONS_EOL_BYTE_ALIGNED 602 */ 603 public static final int TAG_T4_OPTIONS = 292; 604 605 /** 606 * A mask to be used with the "T4Options" tag. 607 * 608 * @see #TAG_T4_OPTIONS 609 */ 610 public static final int T4_OPTIONS_2D_CODING = 1; 611 612 /** 613 * A mask to be used with the "T4Options" tag. 614 * 615 * @see #TAG_T4_OPTIONS 616 */ 617 public static final int T4_OPTIONS_UNCOMPRESSED = 2; 618 619 /** 620 * A mask to be used with the "T4Options" tag. 621 * 622 * @see #TAG_T4_OPTIONS 623 */ 624 public static final int T4_OPTIONS_EOL_BYTE_ALIGNED = 4; 625 626 /** 627 * Constant specifying the "T6Options" tag. 628 * 629 * @see #T6_OPTIONS_UNCOMPRESSED 630 */ 631 public static final int TAG_T6_OPTIONS = 293; 632 633 /** 634 * A mask to be used with the "T6Options" tag. 635 * 636 * @see #TAG_T6_OPTIONS 637 */ 638 public static final int T6_OPTIONS_UNCOMPRESSED = 2; 639 640 /** 641 * Constant specifying the "ResolutionUnit" tag. 642 * 643 * @see #RESOLUTION_UNIT_NONE 644 * @see #RESOLUTION_UNIT_INCH 645 * @see #RESOLUTION_UNIT_CENTIMETER 646 */ 647 public static final int TAG_RESOLUTION_UNIT = 296; 648 649 /** 650 * A value to be used with the "ResolutionUnit" tag. 651 * 652 * @see #TAG_RESOLUTION_UNIT 653 */ 654 public static final int RESOLUTION_UNIT_NONE = 1; 655 656 /** 657 * A value to be used with the "ResolutionUnit" tag. 658 * 659 * @see #TAG_RESOLUTION_UNIT 660 */ 661 public static final int RESOLUTION_UNIT_INCH = 2; 662 663 /** 664 * A value to be used with the "ResolutionUnit" tag. 665 * 666 * @see #TAG_RESOLUTION_UNIT 667 */ 668 public static final int RESOLUTION_UNIT_CENTIMETER = 3; 669 670 671 /** 672 * Constant specifying the "PageNumber" tag. 673 */ 674 public static final int TAG_PAGE_NUMBER = 297; 675 676 /** 677 * Constant specifying the "TransferFunction" tag. 678 */ 679 public static final int TAG_TRANSFER_FUNCTION = 301; 680 681 /** 682 * Constant specifying the "Software" tag. 683 */ 684 public static final int TAG_SOFTWARE = 305; 685 686 /** 687 * Constant specifying the "DateTime" tag. 688 */ 689 public static final int TAG_DATE_TIME = 306; 690 691 /** 692 * Constant specifying the "Artist" tag. 693 */ 694 public static final int TAG_ARTIST = 315; 695 696 /** 697 * Constant specifying the "HostComputer" tag. 698 */ 699 public static final int TAG_HOST_COMPUTER = 316; 700 701 /** 702 * Constant specifying the "Predictor" tag. 703 * 704 * @see #TAG_WHITE_POINT 705 * @see #TAG_PRIMARY_CHROMATICITES 706 * @see #TAG_COLOR_MAP 707 * @see #TAG_HALFTONE_HINTS 708 * @see #TAG_TILE_WIDTH 709 * @see #TAG_TILE_LENGTH 710 * @see #TAG_TILE_OFFSETS 711 * @see #TAG_TILE_BYTE_COUNTS 712 */ 713 public static final int TAG_PREDICTOR = 317; 714 715 /** 716 * A value to be used with the "Predictor" tag. 717 * 718 * @see #TAG_PREDICTOR 719 */ 720 public static final int PREDICTOR_NONE = 1; 721 722 /** 723 * A value to be used with the "Predictor" tag. 724 * 725 * @see #TAG_PREDICTOR 726 */ 727 public static final int PREDICTOR_HORIZONTAL_DIFFERENCING = 2; 728 729 /** 730 * Constant specifying the "WhitePoint" tag. 731 */ 732 public static final int TAG_WHITE_POINT = 318; 733 734 /** 735 * Constant specifying the "PrimaryChromaticites" tag. 736 */ 737 public static final int TAG_PRIMARY_CHROMATICITES = 319; 738 739 /** 740 * Constant specifying the "ColorMap" tag. 741 */ 742 public static final int TAG_COLOR_MAP = 320; 743 744 /** 745 * Constant specifying the "HalftoneHints" tag. 746 */ 747 public static final int TAG_HALFTONE_HINTS = 321; 748 749 /** 750 * Constant specifying the "TileWidth" tag. 751 */ 752 public static final int TAG_TILE_WIDTH = 322; 753 754 /** 755 * Constant specifying the "TileLength" tag. 756 */ 757 public static final int TAG_TILE_LENGTH = 323; 758 759 /** 760 * Constant specifying the "TileOffsets" tag. 761 */ 762 public static final int TAG_TILE_OFFSETS = 324; 763 764 /** 765 * Constant specifying the "TileByteCounts" tag. 766 */ 767 public static final int TAG_TILE_BYTE_COUNTS = 325; 768 769 /** 770 * Constant specifying the "InkSet" tag. 771 * 772 * @see #INK_SET_CMYK 773 * @see #INK_SET_NOT_CMYK 774 */ 775 public static final int TAG_INK_SET = 332; 776 777 /** 778 * A value to be used with the "InkSet" tag. 779 * 780 * @see #TAG_INK_SET 781 */ 782 public static final int INK_SET_CMYK = 1; 783 784 /** 785 * A value to be used with the "InkSet" tag. 786 * 787 * @see #TAG_INK_SET 788 */ 789 public static final int INK_SET_NOT_CMYK = 2; 790 791 /** 792 * Constant specifying the "InkNames" tag. 793 */ 794 public static final int TAG_INK_NAMES = 333; 795 796 /** 797 * Constant specifying the "NumberOfInks" tag. 798 */ 799 public static final int TAG_NUMBER_OF_INKS = 334; 800 801 /** 802 * Constant specifying the "DotRange" tag. 803 */ 804 public static final int TAG_DOT_RANGE = 336; 805 806 /** 807 * Constant specifying the "TargetPrinter" tag. 808 */ 809 public static final int TAG_TARGET_PRINTER = 337; 810 811 /** 812 * Constant specifying the "ExtraSamples" tag. 813 * 814 * @see #EXTRA_SAMPLES_UNSPECIFIED 815 * @see #EXTRA_SAMPLES_ASSOCIATED_ALPHA 816 * @see #EXTRA_SAMPLES_UNASSOCIATED_ALPHA 817 */ 818 public static final int TAG_EXTRA_SAMPLES = 338; 819 820 /** 821 * A value to be used with the "ExtraSamples" tag. 822 * 823 * @see #TAG_EXTRA_SAMPLES 824 */ 825 public static final int EXTRA_SAMPLES_UNSPECIFIED = 0; 826 827 /** 828 * A value to be used with the "ExtraSamples" tag. 829 * 830 * @see #TAG_EXTRA_SAMPLES 831 */ 832 public static final int EXTRA_SAMPLES_ASSOCIATED_ALPHA = 1; 833 834 /** 835 * A value to be used with the "ExtraSamples" tag. 836 * 837 * @see #TAG_EXTRA_SAMPLES 838 */ 839 public static final int EXTRA_SAMPLES_UNASSOCIATED_ALPHA = 2; 840 841 /** 842 * Constant specifying the "SampleFormat" tag. 843 * 844 * @see #SAMPLE_FORMAT_UNSIGNED_INTEGER 845 * @see #SAMPLE_FORMAT_SIGNED_INTEGER 846 * @see #SAMPLE_FORMAT_FLOATING_POINT 847 * @see #SAMPLE_FORMAT_UNDEFINED 848 */ 849 public static final int TAG_SAMPLE_FORMAT = 339; 850 851 /** 852 * A value to be used with the "SampleFormat" tag. 853 * 854 * @see #TAG_SAMPLE_FORMAT 855 */ 856 public static final int SAMPLE_FORMAT_UNSIGNED_INTEGER = 1; 857 858 /** 859 * A value to be used with the "SampleFormat" tag. 860 * 861 * @see #TAG_SAMPLE_FORMAT 862 */ 863 public static final int SAMPLE_FORMAT_SIGNED_INTEGER = 2; 864 865 /** 866 * A value to be used with the "SampleFormat" tag. 867 * 868 * @see #TAG_SAMPLE_FORMAT 869 */ 870 public static final int SAMPLE_FORMAT_FLOATING_POINT = 3; 871 872 /** 873 * A value to be used with the "SampleFormat" tag. 874 * 875 * @see #TAG_SAMPLE_FORMAT 876 */ 877 public static final int SAMPLE_FORMAT_UNDEFINED = 4; 878 879 /** 880 * Constant specifying the "SMinSampleValue" tag. 881 */ 882 public static final int TAG_S_MIN_SAMPLE_VALUE = 340; 883 884 /** 885 * Constant specifying the "SMaxSampleValue" tag. 886 */ 887 public static final int TAG_S_MAX_SAMPLE_VALUE = 341; 888 889 /** 890 * Constant specifying the "TransferRange" tag. 891 */ 892 public static final int TAG_TRANSFER_RANGE = 342; 893 894 /** 895 * Constant specifying the "JPEGTables" tag for 896 * "New style" JPEG-in-TIFF compression. 897 */ 898 public static final int TAG_JPEG_TABLES = 347; 899 900 /** 901 * Constant specifying the "JPEGProc" tag. 902 */ 903 public static final int TAG_JPEG_PROC = 512; 904 905 /** 906 * A value to be used with the "JPEGProc" tag. 907 * 908 * @see #TAG_JPEG_PROC 909 */ 910 public static final int JPEG_PROC_BASELINE = 1; 911 912 /** 913 * A value to be used with the "JPEGProc" tag. 914 * 915 * @see #TAG_JPEG_PROC 916 */ 917 public static final int JPEG_PROC_LOSSLESS = 14; 918 919 /** 920 * Constant specifying the "JPEGInterchangeFormat" tag. 921 */ 922 public static final int TAG_JPEG_INTERCHANGE_FORMAT = 513; 923 924 /** 925 * Constant specifying the "JPEGInterchangeFormatLength" tag. 926 */ 927 public static final int TAG_JPEG_INTERCHANGE_FORMAT_LENGTH = 514; 928 929 /** 930 * Constant specifying the "JPEGRestartInterval" tag. 931 */ 932 public static final int TAG_JPEG_RESTART_INTERVAL = 515; 933 934 /** 935 * Constant specifying the "JPEGLosslessPredictors" tag. 936 */ 937 public static final int TAG_JPEG_LOSSLESS_PREDICTORS = 517; 938 939 /** 940 * Constant specifying the "JPEGPointTransforms" tag. 941 */ 942 public static final int TAG_JPEG_POINT_TRANSFORMS = 518; 943 944 /** 945 * Constant specifying the "JPEGQTables" tag. 946 */ 947 public static final int TAG_JPEG_Q_TABLES = 519; 948 949 /** 950 * Constant specifying the "JPEGDCTables" tag. 951 */ 952 public static final int TAG_JPEG_DC_TABLES = 520; 953 954 /** 955 * Constant specifying the "JPEGACTables" tag. 956 */ 957 public static final int TAG_JPEG_AC_TABLES = 521; 958 959 /** 960 * Constant specifying the "YCbCrCoefficients" tag. 961 */ 962 public static final int TAG_Y_CB_CR_COEFFICIENTS = 529; 963 964 /** 965 * Constant specifying the "YCbCrSubsampling" tag. 966 */ 967 public static final int TAG_Y_CB_CR_SUBSAMPLING = 530; 968 969 /** 970 * Constant specifying the "YCbCrPositioning" tag. 971 * 972 * @see #Y_CB_CR_POSITIONING_CENTERED 973 * @see #Y_CB_CR_POSITIONING_COSITED 974 */ 975 public static final int TAG_Y_CB_CR_POSITIONING = 531; 976 977 /** 978 * A value to be used with the "YCbCrPositioning" tag. 979 * 980 * @see #TAG_Y_CB_CR_POSITIONING 981 */ 982 public static final int Y_CB_CR_POSITIONING_CENTERED = 1; 983 984 /** 985 * A value to be used with the "YCbCrPositioning" tag. 986 * 987 * @see #TAG_Y_CB_CR_POSITIONING 988 */ 989 public static final int Y_CB_CR_POSITIONING_COSITED = 2; 990 991 /** 992 * Constant specifying the "ReferenceBlackWhite" tag. 993 */ 994 public static final int TAG_REFERENCE_BLACK_WHITE = 532; 995 996 /** 997 * Constant specifying the "Copyright" tag. 998 */ 999 public static final int TAG_COPYRIGHT = 33432; 1000 1001 // Common non-baseline tags 1002 1003 // ICC profiles (Spec ICC 1:2001-04, Appendix B) 1004 1005 // 34675 - Embedded ICC Profile (UNDEFINED/any) 1006 1007 /** 1008 * Constant specifying the "ICC Profile" tag. 1009 * 1010 * @see <a href="http://www.color.org/ICC1V42.pdf">ICC Specification, section B.4: Embedding ICC profiles in TIFF files</a> 1011 */ 1012 public static final int TAG_ICC_PROFILE = 34675; 1013 1014 // Artist 1015 1016 static class Artist extends TIFFTag { 1017 1018 public Artist() { 1019 super("Artist", 1020 TAG_ARTIST, 1021 1 << TIFF_ASCII); 1022 } 1023 } 1024 1025 // BitsPerSample 1026 1027 static class BitsPerSample extends TIFFTag { 1028 1029 public BitsPerSample() { 1030 super("BitsPerSample", 1031 TAG_BITS_PER_SAMPLE, 1032 1 << TIFF_SHORT); 1033 } 1034 } 1035 1036 // CellLength 1037 1038 static class CellLength extends TIFFTag { 1039 1040 public CellLength() { 1041 super("CellLength", 1042 TAG_CELL_LENGTH, 1043 1 << TIFF_SHORT, 1044 1); 1045 } 1046 } 1047 1048 // CellWidth tag 1049 1050 static class CellWidth extends TIFFTag { 1051 1052 public CellWidth() { 1053 super("CellWidth", 1054 TAG_CELL_WIDTH, 1055 1 << TIFF_SHORT, 1056 1); 1057 } 1058 } 1059 1060 // ColorMap 1061 1062 static class ColorMap extends TIFFTag { 1063 1064 public ColorMap() { 1065 super("ColorMap", 1066 TAG_COLOR_MAP, 1067 1 << TIFF_SHORT); 1068 } 1069 } 1070 1071 // Compression 1072 1073 static class Compression extends TIFFTag { 1074 1075 public Compression() { 1076 super("Compression", 1077 TAG_COMPRESSION, 1078 1 << TIFF_SHORT, 1079 1); 1080 1081 addValueName(COMPRESSION_NONE, "Uncompressed"); 1082 addValueName(COMPRESSION_CCITT_RLE, "CCITT RLE"); 1083 addValueName(COMPRESSION_CCITT_T_4, "CCITT T.4"); 1084 addValueName(COMPRESSION_CCITT_T_6, "CCITT T.6"); 1085 addValueName(COMPRESSION_LZW, "LZW"); 1086 addValueName(COMPRESSION_OLD_JPEG, "Old JPEG"); 1087 addValueName(COMPRESSION_JPEG, "JPEG"); 1088 addValueName(COMPRESSION_ZLIB, "ZLib"); 1089 addValueName(COMPRESSION_PACKBITS, "PackBits"); 1090 addValueName(COMPRESSION_DEFLATE, "Deflate"); // Non-baseline 1091 1092 // 32771 CCITT 1093 // 32809 ThunderScan 1094 // 32766 NeXT 1095 // 32909 Pixar 1096 // 34676 SGI 1097 // 34677 SGI 1098 } 1099 } 1100 1101 // Copyright 1102 1103 static class Copyright extends TIFFTag { 1104 1105 public Copyright() { 1106 super("Copyright", 1107 TAG_COPYRIGHT, 1108 1 << TIFF_ASCII); 1109 } 1110 } 1111 1112 // DateTime 1113 1114 static class DateTime extends TIFFTag { 1115 1116 public DateTime() { 1117 super("DateTime", 1118 TAG_DATE_TIME, 1119 1 << TIFF_ASCII, 1120 20); 1121 } 1122 } 1123 1124 // DocumentName 1125 1126 static class DocumentName extends TIFFTag { 1127 1128 public DocumentName() { 1129 super("DocumentName", 1130 TAG_DOCUMENT_NAME, 1131 1 << TIFF_ASCII); 1132 } 1133 } 1134 1135 // DotRange 1136 1137 static class DotRange extends TIFFTag { 1138 1139 public DotRange() { 1140 super("DotRange", 1141 TAG_DOT_RANGE, 1142 (1 << TIFF_BYTE) | 1143 (1 << TIFF_SHORT)); 1144 } 1145 } 1146 1147 // ExtraSamples 1148 1149 static class ExtraSamples extends TIFFTag { 1150 1151 public ExtraSamples() { 1152 super("ExtraSamples", 1153 TAG_EXTRA_SAMPLES, 1154 1 << TIFF_SHORT); 1155 1156 addValueName(EXTRA_SAMPLES_UNSPECIFIED, 1157 "Unspecified"); 1158 addValueName(EXTRA_SAMPLES_ASSOCIATED_ALPHA, 1159 "Associated Alpha"); 1160 addValueName(EXTRA_SAMPLES_UNASSOCIATED_ALPHA, 1161 "Unassociated Alpha"); 1162 } 1163 } 1164 1165 // FillOrder 1166 1167 static class FillOrder extends TIFFTag { 1168 1169 public FillOrder() { 1170 super("FillOrder", 1171 TAG_FILL_ORDER, 1172 1 << TIFF_SHORT, 1173 1); 1174 1175 addValueName(FILL_ORDER_LEFT_TO_RIGHT, "LeftToRight"); 1176 addValueName(FILL_ORDER_RIGHT_TO_LEFT, "RightToLeft"); 1177 } 1178 } 1179 1180 // FreeByteCounts 1181 1182 static class FreeByteCounts extends TIFFTag { 1183 1184 public FreeByteCounts() { 1185 super("FreeByteCounts", 1186 TAG_FREE_BYTE_COUNTS, 1187 1 << TIFF_LONG); 1188 } 1189 } 1190 1191 // FreeOffsets 1192 1193 static class FreeOffsets extends TIFFTag { 1194 1195 public FreeOffsets() { 1196 super("FreeOffsets", 1197 TAG_FREE_OFFSETS, 1198 1 << TIFF_LONG); 1199 } 1200 } 1201 1202 // GrayResponseCurve 1203 1204 static class GrayResponseCurve extends TIFFTag { 1205 1206 public GrayResponseCurve() { 1207 super("GrayResponseCurve", 1208 TAG_GRAY_RESPONSE_CURVE, 1209 1 << TIFF_SHORT); 1210 } 1211 } 1212 1213 // GrayResponseUnit 1214 1215 static class GrayResponseUnit extends TIFFTag { 1216 1217 public GrayResponseUnit() { 1218 super("GrayResponseUnit", 1219 TAG_GRAY_RESPONSE_UNIT, 1220 1 << TIFF_SHORT, 1221 1); 1222 1223 addValueName(GRAY_RESPONSE_UNIT_TENTHS, 1224 "Tenths"); 1225 addValueName(GRAY_RESPONSE_UNIT_HUNDREDTHS, 1226 "Hundredths"); 1227 addValueName(GRAY_RESPONSE_UNIT_THOUSANDTHS, 1228 "Thousandths"); 1229 addValueName(GRAY_RESPONSE_UNIT_TEN_THOUSANDTHS, 1230 "Ten-Thousandths"); 1231 addValueName(GRAY_RESPONSE_UNIT_HUNDRED_THOUSANDTHS, 1232 "Hundred-Thousandths"); 1233 } 1234 } 1235 1236 // HalftoneHints 1237 1238 static class HalftoneHints extends TIFFTag { 1239 1240 public HalftoneHints() { 1241 super("HalftoneHints", 1242 TAG_HALFTONE_HINTS, 1243 1 << TIFF_SHORT, 1244 2); 1245 } 1246 } 1247 1248 // HostComputer 1249 1250 static class HostComputer extends TIFFTag { 1251 1252 public HostComputer() { 1253 super("HostComputer", 1254 TAG_HOST_COMPUTER, 1255 1 << TIFF_ASCII); 1256 } 1257 } 1258 1259 // ImageDescription 1260 1261 static class ImageDescription extends TIFFTag { 1262 1263 public ImageDescription() { 1264 super("ImageDescription", 1265 TAG_IMAGE_DESCRIPTION, 1266 1 << TIFF_ASCII); 1267 } 1268 } 1269 1270 // ImageLength tag 1271 1272 static class ImageLength extends TIFFTag { 1273 1274 public ImageLength() { 1275 super("ImageLength", 1276 TAG_IMAGE_LENGTH, 1277 (1 << TIFF_SHORT) | 1278 (1 << TIFF_LONG), 1279 1); 1280 } 1281 } 1282 1283 // ImageWidth tag 1284 1285 static class ImageWidth extends TIFFTag { 1286 1287 public ImageWidth() { 1288 super("ImageWidth", 1289 TAG_IMAGE_WIDTH, 1290 (1 << TIFF_SHORT) | 1291 (1 << TIFF_LONG), 1292 1); 1293 } 1294 } 1295 1296 // InkNames 1297 1298 static class InkNames extends TIFFTag { 1299 1300 public InkNames() { 1301 super("InkNames", 1302 TAG_INK_NAMES, 1303 1 << TIFF_ASCII); 1304 } 1305 } 1306 1307 // InkSet 1308 1309 static class InkSet extends TIFFTag { 1310 1311 public InkSet() { 1312 super("InkSet", 1313 TAG_INK_SET, 1314 1 << TIFF_SHORT, 1315 1); 1316 1317 addValueName(INK_SET_CMYK, "CMYK"); 1318 addValueName(INK_SET_NOT_CMYK, "Not CMYK"); 1319 } 1320 } 1321 1322 // JPEGTables (Tech note) 1323 1324 static class JPEGTables extends TIFFTag { 1325 1326 public JPEGTables() { 1327 super("JPEGTables", 1328 TAG_JPEG_TABLES, 1329 1 << TIFF_UNDEFINED); 1330 } 1331 } 1332 1333 // JPEGACTables 1334 1335 static class JPEGACTables extends TIFFTag { 1336 1337 public JPEGACTables() { 1338 super("JPEGACTables", 1339 TAG_JPEG_AC_TABLES, 1340 1 << TIFF_LONG); 1341 } 1342 } 1343 1344 // JPEGDCTables 1345 1346 static class JPEGDCTables extends TIFFTag { 1347 1348 public JPEGDCTables() { 1349 super("JPEGDCTables", 1350 TAG_JPEG_DC_TABLES, 1351 1 << TIFF_LONG); 1352 } 1353 } 1354 1355 // JPEGInterchangeFormat 1356 1357 static class JPEGInterchangeFormat extends TIFFTag { 1358 1359 public JPEGInterchangeFormat() { 1360 super("JPEGInterchangeFormat", 1361 TAG_JPEG_INTERCHANGE_FORMAT, 1362 1 << TIFF_LONG, 1363 1); 1364 } 1365 } 1366 1367 // JPEGInterchangeFormatLength 1368 1369 static class JPEGInterchangeFormatLength extends TIFFTag { 1370 1371 public JPEGInterchangeFormatLength() { 1372 super("JPEGInterchangeFormatLength", 1373 TAG_JPEG_INTERCHANGE_FORMAT_LENGTH, 1374 1 << TIFF_LONG, 1375 1); 1376 } 1377 } 1378 1379 // JPEGLosslessPredictors 1380 1381 static class JPEGLosslessPredictors extends TIFFTag { 1382 1383 public JPEGLosslessPredictors() { 1384 super("JPEGLosslessPredictors", 1385 TAG_JPEG_LOSSLESS_PREDICTORS, 1386 1 << TIFF_SHORT); 1387 1388 addValueName(1, "A"); 1389 addValueName(2, "B"); 1390 addValueName(3, "C"); 1391 addValueName(4, "A+B-C"); 1392 addValueName(5, "A+((B-C)/2)"); 1393 addValueName(6, "B+((A-C)/2)"); 1394 addValueName(7, "(A+B)/2"); 1395 } 1396 } 1397 1398 // JPEGPointTransforms 1399 1400 static class JPEGPointTransforms extends TIFFTag { 1401 1402 public JPEGPointTransforms() { 1403 super("JPEGPointTransforms", 1404 TAG_JPEG_POINT_TRANSFORMS, 1405 1 << TIFF_SHORT); 1406 } 1407 } 1408 1409 // JPEGProc 1410 1411 static class JPEGProc extends TIFFTag { 1412 1413 public JPEGProc() { 1414 super("JPEGProc", 1415 TAG_JPEG_PROC, 1416 1 << TIFF_SHORT, 1417 1); 1418 1419 addValueName(JPEG_PROC_BASELINE, "Baseline sequential process"); 1420 addValueName(JPEG_PROC_LOSSLESS, 1421 "Lossless process with Huffman coding"); 1422 } 1423 } 1424 1425 // JPEGQTables 1426 1427 static class JPEGQTables extends TIFFTag { 1428 1429 public JPEGQTables() { 1430 super("JPEGQTables", 1431 TAG_JPEG_Q_TABLES, 1432 1 << TIFF_LONG); 1433 } 1434 } 1435 1436 // JPEGRestartInterval 1437 1438 static class JPEGRestartInterval extends TIFFTag { 1439 1440 public JPEGRestartInterval() { 1441 super("JPEGRestartInterval", 1442 TAG_JPEG_RESTART_INTERVAL, 1443 1 << TIFF_SHORT, 1444 1); 1445 } 1446 } 1447 1448 // Make 1449 1450 static class Make extends TIFFTag { 1451 1452 public Make() { 1453 super("Make", 1454 TAG_MAKE, 1455 1 << TIFF_ASCII); 1456 } 1457 } 1458 1459 // MaxSampleValue 1460 1461 static class MaxSampleValue extends TIFFTag { 1462 1463 public MaxSampleValue() { 1464 super("MaxSampleValue", 1465 TAG_MAX_SAMPLE_VALUE, 1466 1 << TIFF_SHORT); 1467 } 1468 } 1469 1470 // MinSampleValue 1471 1472 static class MinSampleValue extends TIFFTag { 1473 1474 public MinSampleValue() { 1475 super("MinSampleValue", 1476 TAG_MIN_SAMPLE_VALUE, 1477 1 << TIFF_SHORT); 1478 } 1479 } 1480 1481 // Model 1482 1483 static class Model extends TIFFTag { 1484 1485 public Model() { 1486 super("Model", 1487 TAG_MODEL, 1488 1 << TIFF_ASCII); 1489 } 1490 } 1491 1492 // NewSubfileType 1493 1494 static class NewSubfileType extends TIFFTag { 1495 1496 public NewSubfileType() { 1497 super("NewSubfileType", 1498 TAG_NEW_SUBFILE_TYPE, 1499 1 << TIFF_LONG, 1500 1); 1501 1502 addValueName(0, 1503 "Default"); 1504 addValueName(NEW_SUBFILE_TYPE_REDUCED_RESOLUTION, 1505 "ReducedResolution"); 1506 addValueName(NEW_SUBFILE_TYPE_SINGLE_PAGE, 1507 "SinglePage"); 1508 addValueName(NEW_SUBFILE_TYPE_SINGLE_PAGE | 1509 NEW_SUBFILE_TYPE_REDUCED_RESOLUTION, 1510 "SinglePage+ReducedResolution"); 1511 addValueName(NEW_SUBFILE_TYPE_TRANSPARENCY, 1512 "Transparency"); 1513 addValueName(NEW_SUBFILE_TYPE_TRANSPARENCY | 1514 NEW_SUBFILE_TYPE_REDUCED_RESOLUTION, 1515 "Transparency+ReducedResolution"); 1516 addValueName(NEW_SUBFILE_TYPE_TRANSPARENCY | 1517 NEW_SUBFILE_TYPE_SINGLE_PAGE, 1518 "Transparency+SinglePage"); 1519 addValueName(NEW_SUBFILE_TYPE_TRANSPARENCY | 1520 NEW_SUBFILE_TYPE_SINGLE_PAGE | 1521 NEW_SUBFILE_TYPE_REDUCED_RESOLUTION, 1522 "Transparency+SinglePage+ReducedResolution"); 1523 } 1524 } 1525 1526 // NumberOfInks 1527 1528 static class NumberOfInks extends TIFFTag { 1529 1530 public NumberOfInks() { 1531 super("NumberOfInks", 1532 TAG_NUMBER_OF_INKS, 1533 1 << TIFF_SHORT, 1534 1); 1535 } 1536 } 1537 1538 // Orientation 1539 1540 static class Orientation extends TIFFTag { 1541 1542 public Orientation() { 1543 super("Orientation", 1544 TAG_ORIENTATION, 1545 1 << TIFF_SHORT, 1546 1); 1547 1548 addValueName(ORIENTATION_ROW_0_TOP_COLUMN_0_LEFT, 1549 "Row 0=Top, Column 0=Left"); 1550 addValueName(ORIENTATION_ROW_0_TOP_COLUMN_0_RIGHT, 1551 "Row 0=Top, Column 0=Right"); 1552 addValueName(ORIENTATION_ROW_0_BOTTOM_COLUMN_0_RIGHT, 1553 "Row 0=Bottom, Column 0=Right"); 1554 addValueName(ORIENTATION_ROW_0_BOTTOM_COLUMN_0_LEFT, 1555 "Row 0=Bottom, Column 0=Left"); 1556 addValueName(ORIENTATION_ROW_0_LEFT_COLUMN_0_TOP, 1557 "Row 0=Left, Column 0=Top"); 1558 addValueName(ORIENTATION_ROW_0_RIGHT_COLUMN_0_TOP, 1559 "Row 0=Right, Column 0=Top"); 1560 addValueName(ORIENTATION_ROW_0_RIGHT_COLUMN_0_BOTTOM, 1561 "Row 0=Right, Column 0=Bottom"); 1562 } 1563 } 1564 1565 // PageName 1566 1567 static class PageName extends TIFFTag { 1568 1569 public PageName() { 1570 super("PageName", 1571 TAG_PAGE_NAME, 1572 1 << TIFF_ASCII); 1573 } 1574 } 1575 1576 // PageNumber 1577 1578 static class PageNumber extends TIFFTag { 1579 1580 public PageNumber() { 1581 super("PageNumber", 1582 TAG_PAGE_NUMBER, 1583 1 << TIFF_SHORT); 1584 } 1585 } 1586 1587 // PhotometricInterpretation 1588 1589 static class PhotometricInterpretation extends TIFFTag { 1590 1591 public PhotometricInterpretation() { 1592 super("PhotometricInterpretation", 1593 TAG_PHOTOMETRIC_INTERPRETATION, 1594 1 << TIFF_SHORT, 1595 1); 1596 1597 addValueName(PHOTOMETRIC_INTERPRETATION_WHITE_IS_ZERO, 1598 "WhiteIsZero"); 1599 addValueName(PHOTOMETRIC_INTERPRETATION_BLACK_IS_ZERO, 1600 "BlackIsZero"); 1601 addValueName(PHOTOMETRIC_INTERPRETATION_RGB, 1602 "RGB"); 1603 addValueName(PHOTOMETRIC_INTERPRETATION_PALETTE_COLOR, 1604 "Palette Color"); 1605 addValueName(PHOTOMETRIC_INTERPRETATION_TRANSPARENCY_MASK, 1606 "Transparency Mask"); 1607 addValueName(PHOTOMETRIC_INTERPRETATION_CMYK, 1608 "CMYK"); 1609 addValueName(PHOTOMETRIC_INTERPRETATION_Y_CB_CR, 1610 "YCbCr"); 1611 addValueName(PHOTOMETRIC_INTERPRETATION_CIELAB, 1612 "CIELAB"); 1613 addValueName(PHOTOMETRIC_INTERPRETATION_ICCLAB, 1614 "ICCLAB"); // Non-baseline 1615 } 1616 } 1617 1618 // PlanarConfiguration 1619 1620 static class PlanarConfiguration extends TIFFTag { 1621 1622 public PlanarConfiguration() { 1623 super("PlanarConfiguration", 1624 TAG_PLANAR_CONFIGURATION, 1625 1 << TIFF_SHORT, 1626 1); 1627 1628 addValueName(PLANAR_CONFIGURATION_CHUNKY, "Chunky"); 1629 addValueName(PLANAR_CONFIGURATION_PLANAR, "Planar"); 1630 } 1631 } 1632 1633 // Predictor 1634 1635 static class Predictor extends TIFFTag { 1636 1637 public Predictor() { 1638 super("Predictor", 1639 TAG_PREDICTOR, 1640 1 << TIFF_SHORT, 1641 1); 1642 1643 addValueName(PREDICTOR_NONE, 1644 "None"); 1645 addValueName(PREDICTOR_HORIZONTAL_DIFFERENCING, 1646 "Horizontal Differencing"); 1647 } 1648 } 1649 1650 // PrimaryChromaticities 1651 1652 static class PrimaryChromaticities extends TIFFTag { 1653 1654 public PrimaryChromaticities() { 1655 super("PrimaryChromaticities", 1656 TAG_PRIMARY_CHROMATICITES, 1657 1 << TIFF_RATIONAL, 1658 6); 1659 } 1660 } 1661 1662 // ReferenceBlackWhite 1663 1664 static class ReferenceBlackWhite extends TIFFTag { 1665 1666 public ReferenceBlackWhite() { 1667 super("ReferenceBlackWhite", 1668 TAG_REFERENCE_BLACK_WHITE, 1669 1 << TIFF_RATIONAL); 1670 } 1671 } 1672 1673 // ResolutionUnit 1674 1675 static class ResolutionUnit extends TIFFTag { 1676 1677 public ResolutionUnit() { 1678 super("ResolutionUnit", 1679 TAG_RESOLUTION_UNIT, 1680 1 << TIFF_SHORT, 1681 1); 1682 1683 addValueName(RESOLUTION_UNIT_NONE, "None"); 1684 addValueName(RESOLUTION_UNIT_INCH, "Inch"); 1685 addValueName(RESOLUTION_UNIT_CENTIMETER, "Centimeter"); 1686 } 1687 } 1688 1689 // RowsPerStrip 1690 1691 static class RowsPerStrip extends TIFFTag { 1692 1693 public RowsPerStrip() { 1694 super("RowsPerStrip", 1695 TAG_ROWS_PER_STRIP, 1696 (1 << TIFF_SHORT) | 1697 (1 << TIFF_LONG), 1698 1); 1699 } 1700 } 1701 1702 // SampleFormat 1703 1704 static class SampleFormat extends TIFFTag { 1705 1706 public SampleFormat() { 1707 super("SampleFormat", 1708 TAG_SAMPLE_FORMAT, 1709 1 << TIFF_SHORT); 1710 1711 addValueName(SAMPLE_FORMAT_UNSIGNED_INTEGER, "Unsigned Integer"); 1712 addValueName(SAMPLE_FORMAT_SIGNED_INTEGER, "Signed Integer"); 1713 addValueName(SAMPLE_FORMAT_FLOATING_POINT, "Floating Point"); 1714 addValueName(SAMPLE_FORMAT_UNDEFINED, "Undefined"); 1715 } 1716 } 1717 1718 // SamplesPerPixel 1719 1720 static class SamplesPerPixel extends TIFFTag { 1721 1722 public SamplesPerPixel() { 1723 super("SamplesPerPixel", 1724 TAG_SAMPLES_PER_PIXEL, 1725 1 << TIFF_SHORT, 1726 1); 1727 } 1728 } 1729 1730 // SMaxSampleValue 1731 1732 static class SMaxSampleValue extends TIFFTag { 1733 1734 public SMaxSampleValue() { 1735 super("SMaxSampleValue", 1736 TAG_S_MAX_SAMPLE_VALUE, 1737 (1 << TIFF_BYTE) | 1738 (1 << TIFF_SHORT) | 1739 (1 << TIFF_LONG) | 1740 (1 << TIFF_RATIONAL) | 1741 (1 << TIFF_SBYTE) | 1742 (1 << TIFF_SSHORT) | 1743 (1 << TIFF_SLONG) | 1744 (1 << TIFF_SRATIONAL) | 1745 (1 << TIFF_FLOAT) | 1746 (1 << TIFF_DOUBLE)); 1747 } 1748 } 1749 1750 // SMinSampleValue 1751 1752 static class SMinSampleValue extends TIFFTag { 1753 1754 public SMinSampleValue() { 1755 super("SMinSampleValue", 1756 TAG_S_MIN_SAMPLE_VALUE, 1757 (1 << TIFF_BYTE) | 1758 (1 << TIFF_SHORT) | 1759 (1 << TIFF_LONG) | 1760 (1 << TIFF_RATIONAL) | 1761 (1 << TIFF_SBYTE) | 1762 (1 << TIFF_SSHORT) | 1763 (1 << TIFF_SLONG) | 1764 (1 << TIFF_SRATIONAL) | 1765 (1 << TIFF_FLOAT) | 1766 (1 << TIFF_DOUBLE)); 1767 } 1768 } 1769 1770 // Software 1771 1772 static class Software extends TIFFTag { 1773 1774 public Software() { 1775 super("Software", 1776 TAG_SOFTWARE, 1777 1 << TIFF_ASCII); 1778 } 1779 } 1780 1781 // StripByteCounts 1782 1783 static class StripByteCounts extends TIFFTag { 1784 1785 public StripByteCounts() { 1786 super("StripByteCounts", 1787 TAG_STRIP_BYTE_COUNTS, 1788 (1 << TIFF_SHORT) | 1789 (1 << TIFF_LONG)); 1790 } 1791 } 1792 1793 // StripOffsets 1794 1795 static class StripOffsets extends TIFFTag { 1796 1797 public StripOffsets() { 1798 super("StripOffsets", 1799 TAG_STRIP_OFFSETS, 1800 (1 << TIFF_SHORT) | 1801 (1 << TIFF_LONG)); 1802 } 1803 } 1804 1805 // SubfileType (deprecated by TIFF but retained for backward compatibility) 1806 1807 static class SubfileType extends TIFFTag { 1808 1809 public SubfileType() { 1810 super("SubfileType", 1811 TAG_SUBFILE_TYPE, 1812 1 << TIFF_SHORT, 1813 1); 1814 1815 addValueName(SUBFILE_TYPE_FULL_RESOLUTION, "FullResolution"); 1816 addValueName(SUBFILE_TYPE_REDUCED_RESOLUTION, "ReducedResolution"); 1817 addValueName(SUBFILE_TYPE_SINGLE_PAGE, "SinglePage"); 1818 } 1819 } 1820 1821 // T4Options 1822 1823 static class T4Options extends TIFFTag { 1824 1825 public T4Options() { 1826 super("T4Options", 1827 TAG_T4_OPTIONS, 1828 1 << TIFF_LONG, 1829 1); 1830 1831 addValueName(0, 1832 "Default 1DCoding"); // 0x00 1833 addValueName(T4_OPTIONS_2D_CODING, 1834 "2DCoding"); // 0x01 1835 addValueName(T4_OPTIONS_UNCOMPRESSED, 1836 "Uncompressed"); // 0x02 1837 addValueName(T4_OPTIONS_2D_CODING | 1838 T4_OPTIONS_UNCOMPRESSED, 1839 "2DCoding+Uncompressed"); // 0x03 1840 addValueName(T4_OPTIONS_EOL_BYTE_ALIGNED, 1841 "EOLByteAligned"); // 0x04 1842 addValueName(T4_OPTIONS_2D_CODING | 1843 T4_OPTIONS_EOL_BYTE_ALIGNED, 1844 "2DCoding+EOLByteAligned"); // 0x05 1845 addValueName(T4_OPTIONS_UNCOMPRESSED | 1846 T4_OPTIONS_EOL_BYTE_ALIGNED, 1847 "Uncompressed+EOLByteAligned"); // 0x06 1848 addValueName(T4_OPTIONS_2D_CODING | 1849 T4_OPTIONS_UNCOMPRESSED | 1850 T4_OPTIONS_EOL_BYTE_ALIGNED, 1851 "2DCoding+Uncompressed+EOLByteAligned"); // 0x07 1852 } 1853 } 1854 1855 // T6Options 1856 1857 static class T6Options extends TIFFTag { 1858 1859 public T6Options() { 1860 super("T6Options", 1861 TAG_T6_OPTIONS, 1862 1 << TIFF_LONG, 1863 1); 1864 1865 addValueName(0, 1866 "Default"); // 0x00 1867 // 0x01 is not possible as bit 0 is unused and always zero. 1868 addValueName(T6_OPTIONS_UNCOMPRESSED, 1869 "Uncompressed"); // 0x02 1870 } 1871 } 1872 1873 // TargetPrinter 1874 1875 static class TargetPrinter extends TIFFTag { 1876 1877 public TargetPrinter() { 1878 super("TargetPrinter", 1879 TAG_TARGET_PRINTER, 1880 1 << TIFF_ASCII); 1881 } 1882 } 1883 1884 // Threshholding 1885 1886 static class Threshholding extends TIFFTag { 1887 1888 public Threshholding() { 1889 super("Threshholding", 1890 TAG_THRESHHOLDING, 1891 1 << TIFF_SHORT, 1892 1); 1893 1894 addValueName(1, "None"); 1895 addValueName(2, "OrderedDither"); 1896 addValueName(3, "RandomizedDither"); 1897 } 1898 } 1899 1900 // TileByteCounts 1901 1902 static class TileByteCounts extends TIFFTag { 1903 1904 public TileByteCounts() { 1905 super("TileByteCounts", 1906 TAG_TILE_BYTE_COUNTS, 1907 (1 << TIFF_SHORT) | 1908 (1 << TIFF_LONG)); 1909 } 1910 } 1911 1912 // TileOffsets 1913 1914 static class TileOffsets extends TIFFTag { 1915 1916 public TileOffsets() { 1917 super("TileOffsets", 1918 TAG_TILE_OFFSETS, 1919 1 << TIFF_LONG); 1920 } 1921 } 1922 1923 // TileLength tag 1924 1925 static class TileLength extends TIFFTag { 1926 1927 public TileLength() { 1928 super("TileLength", 1929 TAG_TILE_LENGTH, 1930 (1 << TIFF_SHORT) | 1931 (1 << TIFF_LONG), 1932 1); 1933 } 1934 } 1935 1936 // TileWidth tag 1937 1938 static class TileWidth extends TIFFTag { 1939 1940 public TileWidth() { 1941 super("TileWidth", 1942 TAG_TILE_WIDTH, 1943 (1 << TIFF_SHORT) | 1944 (1 << TIFF_LONG), 1945 1); 1946 } 1947 } 1948 1949 // TransferFunction 1950 1951 static class TransferFunction extends TIFFTag { 1952 1953 public TransferFunction() { 1954 super("TransferFunction", 1955 TAG_TRANSFER_FUNCTION, 1956 1 << TIFF_SHORT); 1957 } 1958 } 1959 1960 // TransferRange 1961 1962 static class TransferRange extends TIFFTag { 1963 1964 public TransferRange() { 1965 super("TransferRange", 1966 TAG_TRANSFER_RANGE, 1967 1 << TIFF_SHORT, 1968 6); 1969 } 1970 } 1971 1972 // WhitePoint 1973 1974 static class WhitePoint extends TIFFTag { 1975 1976 public WhitePoint() { 1977 super("WhitePoint", 1978 TAG_WHITE_POINT, 1979 1 << TIFF_RATIONAL, 1980 2); 1981 } 1982 } 1983 1984 // XPosition 1985 1986 static class XPosition extends TIFFTag { 1987 1988 public XPosition() { 1989 super("XPosition", 1990 TAG_X_POSITION, 1991 1 << TIFF_RATIONAL, 1992 1); 1993 } 1994 } 1995 1996 // XResolution 1997 1998 static class XResolution extends TIFFTag { 1999 2000 public XResolution() { 2001 super("XResolution", 2002 TAG_X_RESOLUTION, 2003 1 << TIFF_RATIONAL, 2004 1); 2005 } 2006 } 2007 2008 // YCbCrCoefficients 2009 2010 static class YCbCrCoefficients extends TIFFTag { 2011 2012 public YCbCrCoefficients() { 2013 super("YCbCrCoefficients", 2014 TAG_Y_CB_CR_COEFFICIENTS, 2015 1 << TIFF_RATIONAL, 2016 3); 2017 } 2018 } 2019 2020 // YCbCrPositioning 2021 2022 static class YCbCrPositioning extends TIFFTag { 2023 2024 public YCbCrPositioning() { 2025 super("YCbCrPositioning", 2026 TAG_Y_CB_CR_POSITIONING, 2027 1 << TIFF_SHORT, 2028 1); 2029 2030 addValueName(Y_CB_CR_POSITIONING_CENTERED, "Centered"); 2031 addValueName(Y_CB_CR_POSITIONING_COSITED, "Cosited"); 2032 } 2033 } 2034 2035 // YCbCrSubSampling 2036 2037 static class YCbCrSubSampling extends TIFFTag { 2038 2039 public YCbCrSubSampling() { 2040 super("YCbCrSubSampling", 2041 TAG_Y_CB_CR_SUBSAMPLING, 2042 1 << TIFF_SHORT, 2043 2); 2044 } 2045 } 2046 2047 // YPosition 2048 2049 static class YPosition extends TIFFTag { 2050 2051 public YPosition() { 2052 super("YPosition", 2053 TAG_Y_POSITION, 2054 1 << TIFF_RATIONAL, 2055 1); 2056 } 2057 } 2058 2059 // YResolution 2060 2061 static class YResolution extends TIFFTag { 2062 2063 public YResolution() { 2064 super("YResolution", 2065 TAG_Y_RESOLUTION, 2066 1 << TIFF_RATIONAL, 2067 1); 2068 } 2069 } 2070 2071 // Non-6.0 tags 2072 2073 // ICC Profile (Spec. ICC.1:2001-12, File Format for Color Profiles) 2074 2075 static class ICCProfile extends TIFFTag { 2076 2077 public ICCProfile() { 2078 super("ICC Profile", 2079 TAG_ICC_PROFILE, 2080 1 << TIFF_UNDEFINED); 2081 } 2082 } 2083 2084 private static List<TIFFTag> tags; 2085 2086 private static void initTags() { 2087 tags = new ArrayList<TIFFTag>(76); 2088 2089 tags.add(new BaselineTIFFTagSet.Artist()); 2090 tags.add(new BaselineTIFFTagSet.BitsPerSample()); 2091 tags.add(new BaselineTIFFTagSet.CellLength()); 2092 tags.add(new BaselineTIFFTagSet.CellWidth()); 2093 tags.add(new BaselineTIFFTagSet.ColorMap()); 2094 tags.add(new BaselineTIFFTagSet.Compression()); 2095 tags.add(new BaselineTIFFTagSet.Copyright()); 2096 tags.add(new BaselineTIFFTagSet.DateTime()); 2097 tags.add(new BaselineTIFFTagSet.DocumentName()); 2098 tags.add(new BaselineTIFFTagSet.DotRange()); 2099 tags.add(new BaselineTIFFTagSet.ExtraSamples()); 2100 tags.add(new BaselineTIFFTagSet.FillOrder()); 2101 tags.add(new BaselineTIFFTagSet.FreeByteCounts()); 2102 tags.add(new BaselineTIFFTagSet.FreeOffsets()); 2103 tags.add(new BaselineTIFFTagSet.GrayResponseCurve()); 2104 tags.add(new BaselineTIFFTagSet.GrayResponseUnit()); 2105 tags.add(new BaselineTIFFTagSet.HalftoneHints()); 2106 tags.add(new BaselineTIFFTagSet.HostComputer()); 2107 tags.add(new BaselineTIFFTagSet.ImageDescription()); 2108 tags.add(new BaselineTIFFTagSet.ICCProfile()); 2109 tags.add(new BaselineTIFFTagSet.ImageLength()); 2110 tags.add(new BaselineTIFFTagSet.ImageWidth()); 2111 tags.add(new BaselineTIFFTagSet.InkNames()); 2112 tags.add(new BaselineTIFFTagSet.InkSet()); 2113 tags.add(new BaselineTIFFTagSet.JPEGACTables()); 2114 tags.add(new BaselineTIFFTagSet.JPEGDCTables()); 2115 tags.add(new BaselineTIFFTagSet.JPEGInterchangeFormat()); 2116 tags.add(new BaselineTIFFTagSet.JPEGInterchangeFormatLength()); 2117 tags.add(new BaselineTIFFTagSet.JPEGLosslessPredictors()); 2118 tags.add(new BaselineTIFFTagSet.JPEGPointTransforms()); 2119 tags.add(new BaselineTIFFTagSet.JPEGProc()); 2120 tags.add(new BaselineTIFFTagSet.JPEGQTables()); 2121 tags.add(new BaselineTIFFTagSet.JPEGRestartInterval()); 2122 tags.add(new BaselineTIFFTagSet.JPEGTables()); 2123 tags.add(new BaselineTIFFTagSet.Make()); 2124 tags.add(new BaselineTIFFTagSet.MaxSampleValue()); 2125 tags.add(new BaselineTIFFTagSet.MinSampleValue()); 2126 tags.add(new BaselineTIFFTagSet.Model()); 2127 tags.add(new BaselineTIFFTagSet.NewSubfileType()); 2128 tags.add(new BaselineTIFFTagSet.NumberOfInks()); 2129 tags.add(new BaselineTIFFTagSet.Orientation()); 2130 tags.add(new BaselineTIFFTagSet.PageName()); 2131 tags.add(new BaselineTIFFTagSet.PageNumber()); 2132 tags.add(new BaselineTIFFTagSet.PhotometricInterpretation()); 2133 tags.add(new BaselineTIFFTagSet.PlanarConfiguration()); 2134 tags.add(new BaselineTIFFTagSet.Predictor()); 2135 tags.add(new BaselineTIFFTagSet.PrimaryChromaticities()); 2136 tags.add(new BaselineTIFFTagSet.ReferenceBlackWhite()); 2137 tags.add(new BaselineTIFFTagSet.ResolutionUnit()); 2138 tags.add(new BaselineTIFFTagSet.RowsPerStrip()); 2139 tags.add(new BaselineTIFFTagSet.SampleFormat()); 2140 tags.add(new BaselineTIFFTagSet.SamplesPerPixel()); 2141 tags.add(new BaselineTIFFTagSet.SMaxSampleValue()); 2142 tags.add(new BaselineTIFFTagSet.SMinSampleValue()); 2143 tags.add(new BaselineTIFFTagSet.Software()); 2144 tags.add(new BaselineTIFFTagSet.StripByteCounts()); 2145 tags.add(new BaselineTIFFTagSet.StripOffsets()); 2146 tags.add(new BaselineTIFFTagSet.SubfileType()); 2147 tags.add(new BaselineTIFFTagSet.T4Options()); 2148 tags.add(new BaselineTIFFTagSet.T6Options()); 2149 tags.add(new BaselineTIFFTagSet.TargetPrinter()); 2150 tags.add(new BaselineTIFFTagSet.Threshholding()); 2151 tags.add(new BaselineTIFFTagSet.TileByteCounts()); 2152 tags.add(new BaselineTIFFTagSet.TileOffsets()); 2153 tags.add(new BaselineTIFFTagSet.TileLength()); 2154 tags.add(new BaselineTIFFTagSet.TileWidth()); 2155 tags.add(new BaselineTIFFTagSet.TransferFunction()); 2156 tags.add(new BaselineTIFFTagSet.TransferRange()); 2157 tags.add(new BaselineTIFFTagSet.WhitePoint()); 2158 tags.add(new BaselineTIFFTagSet.XPosition()); 2159 tags.add(new BaselineTIFFTagSet.XResolution()); 2160 tags.add(new BaselineTIFFTagSet.YCbCrCoefficients()); 2161 tags.add(new BaselineTIFFTagSet.YCbCrPositioning()); 2162 tags.add(new BaselineTIFFTagSet.YCbCrSubSampling()); 2163 tags.add(new BaselineTIFFTagSet.YPosition()); 2164 tags.add(new BaselineTIFFTagSet.YResolution()); 2165 } 2166 2167 private BaselineTIFFTagSet() { 2168 super(tags); 2169 } 2170 2171 /** 2172 * Returns a shared instance of a {@code BaselineTIFFTagSet}. 2173 * 2174 * @return a {@code BaselineTIFFTagSet} instance. 2175 */ 2176 public synchronized static BaselineTIFFTagSet getInstance() { 2177 if (theInstance == null) { 2178 initTags(); 2179 theInstance = new BaselineTIFFTagSet(); 2180 tags = null; 2181 } 2182 return theInstance; 2183 } 2184 }