TIFF圖像文件格式詳解(3)

基本TIFF TAGS

本頁主要摘自 http://www.awaresystems.be/imaging/tiff/tifftags/baseline.html。每一個TAG均有原始鏈接,可以點擊查看詳細的描述。

 

這些基本Tag是所有TIFF編解碼器必須支持的Tag

 

名稱簡短描述
十進制碼十六進制
254 00FE NewSubfileType

新的子文件類型標識 LONG 長度爲1

用比特來標識圖像的類型

Bit0如果是1代表縮略圖

Bit1如果是1代表多頁圖像中的某一頁

Bit2如果是1代表它是透明度掩碼圖像

其餘的位數暫時沒有定義。與SubfileType的是,此Tag用比特位來區分文件類型而不是用值來區分

255 00FF SubfileType

子文件類型標識 SHORT 長度爲1

1 全分辨率圖像

2 縮小分辨率的圖像

3 多頁圖像的某一頁

過時的Tag,已不再使用。

256 0100 ImageWidth

圖像寬度 SHORT或者LONG 長度爲1

257 0101 ImageLength 圖像高度 SHORT或者LONG 長度爲1
258 0102 BitsPerSample

每個分量的Bit數 SHORT 長度爲SamplesPerPixel

259 0103 Compression

壓縮類型 SHORT 長度爲1

隨着TIFF的不斷擴張,目前支持多達幾十種的壓縮方式。就我個人看來,最需要關注的有以下兩個值:

Compression=1: 沒有壓縮

Compression=7:JPEG壓縮。 如果是RGB圖像並且SamplesPerPixel=3,則是標準的有損JPEG壓縮。如果是CFA圖像,則是Lossless JPEG

262 0106 PhotometricInterpretation

顏色空間 SHORT 長度爲1

0 = WhiteIsZero. 應用於灰度或者二值圖像, 0對應最亮灰度.
1 = BlackIsZero. 應用於灰度或者二值圖像. 0對應最暗灰度。
2 = RGB. 正常RGB圖像,存儲順序爲R,G,B.
3 = Palette color. 索引圖像, ColorMap必須定義,SamplesPerPixel必須1.

32803 = CFA (Color Filter Array)

263 0107 Threshholding 定義了轉換成二值圖像的閾值,忽略之
264 0108 CellWidth The width of the dithering or halftoning matrix used to create a dithered or halftoned bilevel file.
265 0109 CellLength The length of the dithering or halftoning matrix used to create a dithered or halftoned bilevel file.
266 010A FillOrder 在同一字節中的邏輯順序。一般不做定義,要定義的話建議用1
270 010E ImageDescription 字符串, 對圖像的描述
271 010F Make 字符串, 生產廠商的描述
272 0110 Model 字符串
273 0111 StripOffsets

每個Strip的偏移量 SHORT或者LONG

N = StripsPerImage for PlanarConfiguration equal to 1; N = SamplesPerPixel * StripsPerImage for PlanarConfiguration equal to 2

274 0112 Orientation The orientation of the image with respect to the rows and columns.
277 0115 SamplesPerPixel 每個象素的通道數 SHORT 長度爲1
278 0116 RowsPerStrip

每個Strip有多少行 SHORT或者LONG 長度爲1。Default是無限大

StripsPerImage = floor ((ImageLength + RowsPerStrip - 1) / RowsPerStrip).

279 0117 StripByteCounts

每個Strip的長度 SHORT或者LONG

N = StripsPerImage for PlanarConfiguration equal to 1; N = SamplesPerPixel * StripsPerImage for PlanarConfiguration equal to 2

280 0118 MinSampleValue The minimum component value used.
281 0119 MaxSampleValue The maximum component value used.
282 011A XResolution The number of pixels per ResolutionUnit in the ImageWidth direction.
283 011B YResolution The number of pixels per ResolutionUnit in the ImageLength direction.
284 011C PlanarConfiguration How the components of each pixel are stored.
288 0120 FreeOffsets For each string of contiguous unused bytes in a TIFF file, the byte offset of the string.
289 0121 FreeByteCounts For each string of contiguous unused bytes in a TIFF file, the number of bytes in the string.
290 0122 GrayResponseUnit The precision of the information contained in the GrayResponseCurve.
291 0123 GrayResponseCurve For grayscale data, the optical density of each possible pixel value.
296 0128 ResolutionUnit The unit of measurement for XResolution and YResolution.
305 0131 Software Name and version number of the software package(s) used to create the image.
306 0132 DateTime Date and time of image creation.
315 013B Artist Person who created the image.
316 013C HostComputer The computer and/or operating system in use at the time of image creation.
320 0140 ColorMap 調色板
338 0152 ExtraSamples Description of extra components.
33432 8298 Copyright Copyright notice.
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章