Sometimes it’s not really obvious what a particular metadata property is supposed to mean. A good example of such vague property is a numeric flag or enumeration. For example, here is the description of the EXIF ExposureProgram tag taken from the official EXIF specification:
Note
The class of the program used by the camera to set exposure when the picture is taken. The tag values are as follows.
0 = Not defined
1 = Manual
2 = Normal program
3 = Aperture priority
4 = Shutter priority
5 = Creative program
6 = Action program
7 = Portrait mode
8 = Landscape mode
As you can see, all modes are represented by numeric values. If you are not familiar with the specification, you will get a hard time converting these bare numbers to something meaningful. This is where interpreted values come into play. They provide a user-friendly description of the original property value. The code snippet below demonstrates how to extract the ExposureProgram property and display its original value and interpreted value.
try(Metadatametadata=newMetadata("D:\\input.heic")){IExifroot=(IExif)metadata.getRootPackage();if(root.getExifPackage()!=null){TiffShortTagproperty=(TiffShortTag)root.getExifPackage().getExifIfdPackage().getByTiffTagID(TiffTagID.ExposureProgram);if(property!=null){System.out.println(property.getTagValue()[0]);// 2
System.out.println(property.getInterpretedValue());// Normal program
}}}
From release to release, we add interpreters to metadata properties extracted from various formats. To get a full list of properties having interpreted values for a particular file please use the below example: