#[non_exhaustive]pub enum ExifTag {
Show 128 variants
Make = 271,
Model = 272,
Orientation = 274,
ImageWidth = 256,
ImageHeight = 257,
ISOSpeedRatings = 34_855,
ShutterSpeedValue = 37_377,
ExposureTime = 33_434,
FNumber = 33_437,
ExifImageWidth = 40_962,
ExifImageHeight = 40_963,
DateTimeOriginal = 36_867,
CreateDate = 36_868,
ModifyDate = 306,
OffsetTime = 36_880,
OffsetTimeOriginal = 36_881,
OffsetTimeDigitized = 36_882,
GPSLatitudeRef = 1,
GPSLatitude = 2,
GPSLongitudeRef = 3,
GPSLongitude = 4,
GPSAltitudeRef = 5,
GPSAltitude = 6,
GPSVersionID = 0,
ExifOffset = 34_665,
GPSInfo = 34_853,
ImageDescription = 270,
XResolution = 282,
YResolution = 283,
ResolutionUnit = 296,
Software = 305,
HostComputer = 316,
WhitePoint = 318,
PrimaryChromaticities = 319,
YCbCrCoefficients = 529,
ReferenceBlackWhite = 532,
Copyright = 33_432,
ExposureProgram = 34_850,
SpectralSensitivity = 34_852,
OECF = 34_856,
SensitivityType = 34_864,
ExifVersion = 36_864,
ApertureValue = 37_378,
BrightnessValue = 37_379,
ExposureBiasValue = 37_380,
MaxApertureValue = 37_381,
SubjectDistance = 37_382,
MeteringMode = 37_383,
LightSource = 37_384,
Flash = 37_385,
FocalLength = 37_386,
SubjectArea = 37_396,
MakerNote = 37_500,
UserComment = 37_510,
FlashPixVersion = 40_960,
ColorSpace = 40_961,
RelatedSoundFile = 40_964,
FlashEnergy = 41_483,
FocalPlaneXResolution = 41_486,
FocalPlaneYResolution = 41_487,
FocalPlaneResolutionUnit = 41_488,
SubjectLocation = 41_492,
ExposureIndex = 41_493,
SensingMethod = 41_495,
FileSource = 41_728,
SceneType = 41_729,
CFAPattern = 41_730,
CustomRendered = 41_985,
ExposureMode = 41_986,
WhiteBalanceMode = 41_987,
DigitalZoomRatio = 41_988,
FocalLengthIn35mmFilm = 41_989,
SceneCaptureType = 41_990,
GainControl = 41_991,
Contrast = 41_992,
Saturation = 41_993,
Sharpness = 41_994,
DeviceSettingDescription = 41_995,
SubjectDistanceRange = 41_996,
ImageUniqueID = 42_016,
CameraSerialNumber = 42_033,
LensSpecification = 42_034,
LensMake = 42_035,
LensModel = 42_036,
LensSerialNumber = 42_037,
Gamma = 42_240,
GPSTimeStamp = 7,
GPSSatellites = 8,
GPSStatus = 9,
GPSMeasureMode = 10,
GPSDOP = 11,
GPSSpeedRef = 12,
GPSSpeed = 13,
GPSTrackRef = 14,
GPSTrack = 15,
GPSImgDirectionRef = 16,
GPSImgDirection = 17,
GPSMapDatum = 18,
GPSDestLatitudeRef = 19,
GPSDestLatitude = 20,
GPSDestLongitudeRef = 21,
GPSDestLongitude = 22,
GPSDestBearingRef = 23,
GPSDestBearing = 24,
GPSDestDistanceRef = 25,
GPSDestDistance = 26,
GPSProcessingMethod = 27,
GPSAreaInformation = 28,
GPSDateStamp = 29,
GPSDifferential = 30,
ProcessingSoftware = 65_547,
InteropIndex = 131_073,
InteropVersion = 131_074,
YCbCrPositioning = 531,
RecommendedExposureIndex = 34_866,
SubSecTimeDigitized = 37_522,
SubSecTimeOriginal = 37_521,
SubSecTime = 37_520,
InteropOffset = 40_965,
ComponentsConfiguration = 37_121,
ThumbnailOffset = 513,
ThumbnailLength = 514,
Compression = 259,
BitsPerSample = 258,
PhotometricInterpretation = 262,
SamplesPerPixel = 277,
RowsPerStrip = 278,
PlanarConfiguration = 284,
}Expand description
Defines recognized Exif tags. All tags can be parsed, no matter if it is defined here. This enum definition is just for ease of use.
You can always get the entry value by raw tag code which is an u16 value.
See ExifIterEntry::tag (returns TagOrCode
which exposes .code()) and Exif::get_by_code.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Make = 271
Model = 272
Orientation = 274
ImageWidth = 256
ImageHeight = 257
ISOSpeedRatings = 34_855
ShutterSpeedValue = 37_377
ExposureTime = 33_434
FNumber = 33_437
ExifImageWidth = 40_962
ExifImageHeight = 40_963
DateTimeOriginal = 36_867
CreateDate = 36_868
ModifyDate = 306
OffsetTime = 36_880
OffsetTimeOriginal = 36_881
OffsetTimeDigitized = 36_882
GPSLatitudeRef = 1
GPSLatitude = 2
GPSLongitudeRef = 3
GPSLongitude = 4
GPSAltitudeRef = 5
GPSAltitude = 6
GPSVersionID = 0
ExifOffset = 34_665
GPSInfo = 34_853
ImageDescription = 270
XResolution = 282
YResolution = 283
ResolutionUnit = 296
Software = 305
HostComputer = 316
WhitePoint = 318
PrimaryChromaticities = 319
YCbCrCoefficients = 529
ReferenceBlackWhite = 532
Copyright = 33_432
ExposureProgram = 34_850
SpectralSensitivity = 34_852
OECF = 34_856
SensitivityType = 34_864
ExifVersion = 36_864
ApertureValue = 37_378
BrightnessValue = 37_379
ExposureBiasValue = 37_380
MaxApertureValue = 37_381
SubjectDistance = 37_382
MeteringMode = 37_383
LightSource = 37_384
Flash = 37_385
FocalLength = 37_386
SubjectArea = 37_396
MakerNote = 37_500
UserComment = 37_510
FlashPixVersion = 40_960
ColorSpace = 40_961
RelatedSoundFile = 40_964
FlashEnergy = 41_483
FocalPlaneXResolution = 41_486
FocalPlaneYResolution = 41_487
FocalPlaneResolutionUnit = 41_488
SubjectLocation = 41_492
ExposureIndex = 41_493
SensingMethod = 41_495
FileSource = 41_728
SceneType = 41_729
CFAPattern = 41_730
CustomRendered = 41_985
ExposureMode = 41_986
WhiteBalanceMode = 41_987
DigitalZoomRatio = 41_988
FocalLengthIn35mmFilm = 41_989
SceneCaptureType = 41_990
GainControl = 41_991
Contrast = 41_992
Saturation = 41_993
Sharpness = 41_994
DeviceSettingDescription = 41_995
SubjectDistanceRange = 41_996
ImageUniqueID = 42_016
CameraSerialNumber = 42_033
LensSpecification = 42_034
LensMake = 42_035
LensModel = 42_036
LensSerialNumber = 42_037
Gamma = 42_240
GPSTimeStamp = 7
GPSSatellites = 8
GPSStatus = 9
GPSMeasureMode = 10
GPSDOP = 11
GPSSpeedRef = 12
GPSSpeed = 13
GPSTrackRef = 14
GPSTrack = 15
GPSImgDirectionRef = 16
GPSImgDirection = 17
GPSMapDatum = 18
GPSDestLatitudeRef = 19
GPSDestLatitude = 20
GPSDestLongitudeRef = 21
GPSDestLongitude = 22
GPSDestBearingRef = 23
GPSDestBearing = 24
GPSDestDistanceRef = 25
GPSDestDistance = 26
GPSProcessingMethod = 27
GPSAreaInformation = 28
GPSDateStamp = 29
GPSDifferential = 30
ProcessingSoftware = 65_547
0x000b in the TIFF namespace (GPSDOP uses the same code in GPS).
InteropIndex = 131_073
0x0001 in the Interop namespace (GPSLatitudeRef in GPS).
InteropVersion = 131_074
0x0002 in the Interop namespace (GPSLatitude in GPS).
YCbCrPositioning = 531
RecommendedExposureIndex = 34_866
SubSecTimeDigitized = 37_522
SubSecTimeOriginal = 37_521
SubSecTime = 37_520
InteropOffset = 40_965
ComponentsConfiguration = 37_121
ThumbnailOffset = 513
ThumbnailLength = 514
Compression = 259
BitsPerSample = 258
PhotometricInterpretation = 262
SamplesPerPixel = 277
RowsPerStrip = 278
PlanarConfiguration = 284
Implementations§
Source§impl ExifTag
impl ExifTag
pub const fn code(self) -> u16
pub const fn name(self) -> &'static str
Sourcepub fn from_code_in(kind: IfdKind, code: u16) -> Option<Self>
pub fn from_code_in(kind: IfdKind, code: u16) -> Option<Self>
Resolve a raw code within a known IFD namespace.
Unlike Self::from_code this cannot mislabel: a code that the given
namespace does not define returns None rather than falling through to
some other namespace’s meaning.
Sourcepub fn namespace(self) -> Option<IfdKind>
pub fn namespace(self) -> Option<IfdKind>
The namespace that defines this tag, but only when its code is
ambiguous — i.e. some other IFD assigns a different tag to the same
code. Returns None for codes with a single meaning, which can safely
be looked up in any namespace.
use nom_exif::{ExifTag, IfdKind};
assert_eq!(ExifTag::GPSDOP.namespace(), Some(IfdKind::Gps));
assert_eq!(ExifTag::ProcessingSoftware.namespace(), Some(IfdKind::Tiff));
assert_eq!(ExifTag::Make.namespace(), None); // 0x010f means Make everywhere