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