Class RawTiffParser

All Implemented Interfaces:
Serializable, SelfConfiguring, EnrichingParser, Parser

public class RawTiffParser extends TiffParser
Parser for TIFF-based camera raw images: Nikon NEF/NRW, Sony ARW/SRF/SR2, Pentax PEF/PTX, Samsung SRW, Adobe DNG and Canon CR2.

These formats are TIFF containers: metadata extraction is inherited from TiffParser. In addition, this parser extracts the camera-generated JPEG preview images embedded in the raw file and hands them to the EmbeddedDocumentExtractor. Previews are referenced from the IFD chain or from SubIFDs, either via the JPEGInterchangeFormat/ JPEGInterchangeFormatLength tags or as a single JPEG-compressed strip (DNG, CR2). Strips holding raw sensor data are also JPEG-encoded in some formats (lossless JPEG in CR2 and DNG), so strip candidates are only accepted for displayable images: PhotometricInterpretation RGB or YCbCr, or 8 bits per sample when PhotometricInterpretation is absent (CR2). Both classic TIFF and BigTIFF containers (allowed for DNG since spec version 1.7) are supported for preview extraction; for BigTIFF, EXIF metadata extraction is skipped until metadata-extractor supports it.

Of the previews that are extracted (see the length limits in RawTiffParser.RawTiffParserConfig), the largest by JPEG byte length is marked TikaCoreProperties.EmbeddedResourceType.THUMBNAIL, any smaller ones are TikaCoreProperties.EmbeddedResourceType.INLINE images (TIKA-4851).

See Also: