ImageGear .NET v25.0 - Updated
Metadata Structure
User Guide > File Formats and Compressions > File Formats > Metadata Structures > Metadata Structure

image metadata structure consists of three sections, which are represented by sub-trees:

Common Section

The Common sub-tree contains values that are common or useful for all raw files.

All values in the Common sub-tree have Type = VALUE_ITEM and are Read Only.

Name Id Native Type Value count Description
ImageWidth ImGearDCRAWTagIDs.IMAGEWIDTH UINT32 1 Image width after that masked pixels were trimmed out
ImageHeight ImGearDCRAWTagIDs.IMAGEHEIGHT UINT32 1 Image height after that masked pixels were trimmed out
BitsPerSample ImGearDCRAWTagIDs.BITSPERSAMPLE UINT32 1..3 Bits per sample in the original raw image (before reconstruction)
PhotometricInterpretation ImGearDCRAWTagIDs.PHOTOMETRICINTERPRETATION UINT32 1 Photometric interpretation of the original raw image
RawLeft ImGearDCRAWTagIDs.RAWLEFT UINT32 1 X coordinate of first column of non-masked pixels
RawTop ImGearDCRAWTagIDs.RAWTOP UINT32 1 Y coordinate of first row of non-masked pixels
RawWidth ImGearDCRAWTagIDs.RAWWIDTH UINT32 1 Raw Image Width, including masked pixels
RawHeight ImGearDCRAWTagIDs.RAWHEIGHT UINT32 1 Raw Image Height, including masked pixels
ColorPlanes ImGearDCRAWTagIDs.COLORPLANES UINT32 1 Number of colors in the CFA pattern
SamplesPerPixel ImGearDCRAWTagIDs.SAMPLESPERPIXEL UINT32 1 Number of samples per pixel in the original image, before reconstruction
Make ImGearDCRAWTagIDs.MAKE STRING 1 Name of the camera manufacturer
Model ImGearDCRAWTagIDs.MODEL STRING 1 Name of the camera model
UniqueCameraModel ImGearDCRAWTagIDs.UNIQUECAMERAMODEL STRING 1 Unique, non-localized name for the camera model that created the image in the raw file.
TimeStamp ImGearDCRAWTagIDs.TIMESTAMP STRING 1 Time stamp
CFARepeatPatternDim ImGearDCRAWTagIDs.CFAREPEATPATTERNDIM UINT16 2 This tag encodes the number of pixels horizontally and vertically that are needed to uniquely define the repeat pattern of the color filter array.
CFAPattern ImGearDCRAWTagIDs.CFAPATTERN INT8 CFARepeatPatternDim[0] * CFARepeatPatternDim[1] This tag encodes the actual color filter array geometric pattern of the image sensor used to capture the single sensor color image.
AsShotNeutral ImGearDCRAWTagIDs.ASSHOTNEUTRAL RATIONAL_INT32 ColorPlanes Specifies the selected white balance at time of capture, encoded as the coordinates of a perfectly neutral color in linear reference space values.
WhiteLevel ImGearDCRAWTagIDs.WHITELEVEL RATIONAL_INT32 1 Image pixel value that corresponds to fully saturated encoding level.
CalibrationIlluminant1 ImGearDCRAWTagIDs.CALIBRATIONILLUMINANT1 UINT16 1 The illuminant used for ColorMatrix1 color conversion matrix. Allowed values are the same as allowed values for LightSource EXIF tag (see Exif specification).
CalibrationIlluminant2 ImGearDCRAWTagIDs.CALIBRATIONILLUMINANT1 UINT16 1 The illuminant used for ColorMatrix2 color conversion matrix. Allowed values are the same as allowed values for LightSource EXIF tag (see Exif specification).
ColorMatrix1 ImGearDCRAWTagIDs.COLORMATRIX1 RATIONAL_INT32 ColorPlanes * 3 Conversion matrix from XYZ to camera color space, for illuminant specified by CalibrationIlluminant1 tag. Matrix is stored in row scan order.
ColorMatrix2 ImGearDCRAWTagIDs.COLORMATRIX2 RATIONAL_INT32 ColorPlanes * 3 Conversion matrix from XYZ to camera color space, for illuminant specified by CalibrationIlluminant2 tag. Matrix is stored in row scan order.
BaselineExposure ImGearDCRAWTagIDs.BASELINEEXPOSURE RATIONAL_INT32 1 Specifies baseline exposure of the camera, in EV units. Application may use this value to adjust exposure compensation for particular camera model.

Format-Specific Level

This level includes format-specific metadata that is found in the image (CIFF, EXIF, or TIFF). See corresponding sections for structure of metadata for these formats:

Statistics

This section contains data that is collected during image loading, rather than obtained from image's header or metadata. ImGearFileFormats.LoadPage creates this section, but ImGearFileFormats.LoadPageHeader does not, because it does not load pixel data.

Currently, the Statistics section contains image Black Level information.

Black Level specifies pixel intensity, caused by heat rather than by light. Even in absolute darkness, camera sensors report non-zero pixel intensities. Black Level should be subtracted from raw image pixel intensities in the beginning of the processing cycle. If this is not done, the image may look pale or have an unwanted tint.

In order to collect Black Level information, many digital cameras expose only the central part of the sensor to the light, and leave edges of the sensor obscured. Intensities obtained from this obscured area can be averaged to calculate Black Level.

BlackLevel information is represented as a two dimensional array, containing averaged black level values for each element of a color filter array cell.

The following tags can be present in the Statistics section:

Name ID Native Type Value Count Description
BlackLevelRepeatDim ImGearDCRAWTagIDs.BLACKLEVELREPEATDIM UINT16 2 This tag specifies repeat pattern size for the "BlackLevel" tag.
BlackLevel ImGearDCRAWTagIDs.BLACKLEVEL UINT32 BlackLevelRepeatDim[0] * BlackLevelRepeatDim[1] This tag specifies the image Black Level.