You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

93 lines
2.3KB

  1. /*
  2. * Copyright (c) 2006 Konstantin Shishkov
  3. *
  4. * This file is part of FFmpeg.
  5. *
  6. * FFmpeg is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU Lesser General Public
  8. * License as published by the Free Software Foundation; either
  9. * version 2.1 of the License, or (at your option) any later version.
  10. *
  11. * FFmpeg is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  14. * Lesser General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU Lesser General Public
  17. * License along with FFmpeg; if not, write to the Free Software
  18. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  19. */
  20. /**
  21. * @file
  22. * TIFF tables
  23. *
  24. * For more information about the TIFF format, check the official docs at:
  25. * http://partners.adobe.com/public/developer/tiff/index.html
  26. * @author Konstantin Shishkov
  27. */
  28. #ifndef AVCODEC_TIFF_H
  29. #define AVCODEC_TIFF_H
  30. #include <stdint.h>
  31. /** abridged list of TIFF tags */
  32. enum TiffTags{
  33. TIFF_SUBFILE = 0xfe,
  34. TIFF_WIDTH = 0x100,
  35. TIFF_HEIGHT,
  36. TIFF_BPP,
  37. TIFF_COMPR,
  38. TIFF_INVERT = 0x106,
  39. TIFF_FILL_ORDER = 0x10A,
  40. TIFF_STRIP_OFFS = 0x111,
  41. TIFF_SAMPLES_PER_PIXEL = 0x115,
  42. TIFF_ROWSPERSTRIP = 0x116,
  43. TIFF_STRIP_SIZE,
  44. TIFF_XRES = 0x11A,
  45. TIFF_YRES = 0x11B,
  46. TIFF_PLANAR = 0x11C,
  47. TIFF_XPOS = 0x11E,
  48. TIFF_YPOS = 0x11F,
  49. TIFF_T4OPTIONS = 0x124,
  50. TIFF_T6OPTIONS,
  51. TIFF_RES_UNIT = 0x128,
  52. TIFF_SOFTWARE_NAME = 0x131,
  53. TIFF_PREDICTOR = 0x13D,
  54. TIFF_PAL = 0x140,
  55. TIFF_YCBCR_COEFFICIENTS = 0x211,
  56. TIFF_YCBCR_SUBSAMPLING = 0x212,
  57. TIFF_YCBCR_POSITIONING = 0x213,
  58. TIFF_REFERENCE_BW = 0x214,
  59. };
  60. /** list of TIFF compression types */
  61. enum TiffCompr{
  62. TIFF_RAW = 1,
  63. TIFF_CCITT_RLE,
  64. TIFF_G3,
  65. TIFF_G4,
  66. TIFF_LZW,
  67. TIFF_JPEG,
  68. TIFF_NEWJPEG,
  69. TIFF_ADOBE_DEFLATE,
  70. TIFF_PACKBITS = 0x8005,
  71. TIFF_DEFLATE = 0x80B2
  72. };
  73. enum TiffTypes{
  74. TIFF_BYTE = 1,
  75. TIFF_STRING,
  76. TIFF_SHORT,
  77. TIFF_LONG,
  78. TIFF_RATIONAL,
  79. };
  80. /** sizes of various TIFF field types (string size = 100)*/
  81. static const uint8_t type_sizes[6] = {
  82. 0, 1, 100, 2, 4, 8
  83. };
  84. #endif /* AVCODEC_TIFF_H */