![]() |
NDEVR
API Documentation
|
Stores and parses EXIF and XMP metadata extracted from a JPEG image stream. More...
Classes | |
| struct | Calibration_t |
| Camera calibration information derived from EXIF metadata. More... | |
| struct | Geolocation_t |
| GPS and flight telemetry information embedded in the image file. More... | |
| struct | GPano_t |
| Google Photo Sphere (GPano) spherical metadata. More... | |
| struct | LensInfo_t |
| Lens information extracted from EXIF metadata. More... | |
| struct | MicroVideo_t |
| Google camera micro-video metadata embedded in the image file. More... | |
Public Member Functions | |
| EXIFInfo () | |
| Default constructor. | |
| EXIFInfo (const uint8_t *data, unsigned length) | |
| Constructs and immediately parses EXIF/XMP data from a raw memory buffer. | |
| EXIFInfo (EXIFStream &stream) | |
| Constructs and immediately parses EXIF/XMP data from the given EXIFStream. | |
| EXIFInfo (std::istream &stream) | |
| Constructs and immediately parses EXIF/XMP data from a standard input stream. | |
| void | clear () |
| Resets all data members to their default values. | |
| int | parseFrom (const uint8_t *data, unsigned length) |
| Parses EXIF and XMP metadata from a JPEG image in a raw memory buffer. | |
| int | parseFrom (EXIFStream &stream) |
| Parses EXIF and XMP metadata from a JPEG image provided via an EXIFStream. | |
| int | parseFrom (std::istream &stream) |
| Parses EXIF and XMP metadata from a JPEG image provided via a standard input stream. | |
| int | parseFromEXIFSegment (const uint8_t *buf, unsigned len) |
| Parses metadata from a standalone EXIF segment (blob starting with "Exif\0\0"). | |
| int | parseFromXMPSegment (const uint8_t *buf, unsigned len) |
| Parses metadata from a standalone XMP segment. | |
| int | parseFromXMPSegmentXML (const char *szXML, unsigned len) |
| Parses metadata from raw XMP XML content. | |
Public Attributes | |
| double | ApertureValue |
| Lens aperture (APEX value). | |
| uint16_t | BitsPerSample |
| Number of bits per component. | |
| double | BrightnessValue |
| Brightness value (APEX). | |
| struct EXIFInfo::Calibration_t | Calibration |
| Camera calibration data. | |
| String | Copyright |
| File copyright information. | |
| String | DateTime |
| File change date and time. | |
| String | DateTimeDigitized |
| Digitization date and time (may not exist). | |
| String | DateTimeOriginal |
| Original capture date and time (may not exist). | |
| double | ExposureBiasValue |
| Exposure bias value in EV. | |
| uint16_t | ExposureProgram |
| Exposure program used. | |
| double | ExposureTime |
| Exposure time in seconds. | |
| uint32_t | Fields |
| Bitmask of FieldCode values indicating which metadata categories are available. | |
| uint16_t | Flash |
| Flash status bitmask. | |
| double | FNumber |
| F-number (f-stop) of the lens. | |
| double | FocalLength |
| Focal length of the lens in millimeters. | |
| struct EXIFInfo::Geolocation_t | GeoLocation |
| GPS and flight telemetry data. | |
| struct EXIFInfo::GPano_t | GPano |
| Spherical/panorama metadata. | |
| String | ImageDescription |
| Image description. | |
| uint32_t | ImageHeight |
| Image height reported in EXIF data (pixels). | |
| uint32_t | ImageWidth |
| Image width reported in EXIF data (pixels). | |
| uint16_t | ISOSpeedRatings |
| ISO speed rating. | |
| struct EXIFInfo::LensInfo_t | LensInfo |
| Lens metadata. | |
| uint16_t | LightSource |
| Kind of light source. | |
| String | Make |
| Camera manufacturer's name. | |
| uint16_t | MeteringMode |
| Metering mode. | |
| struct EXIFInfo::MicroVideo_t | MicroVideo |
| Embedded micro-video metadata. | |
| String | Model |
| Camera model. | |
| uint16_t | Orientation |
| Image orientation (EXIF tag 0x0112). | |
| uint16_t | ProjectionType |
| Projection type. | |
| uint32_t | RelatedImageHeight |
| Original image height reported in EXIF data (pixels). | |
| uint32_t | RelatedImageWidth |
| Original image width reported in EXIF data (pixels). | |
| uint16_t | ResolutionUnit |
| Unit of measurement for XResolution and YResolution. | |
| String | SerialNumber |
| Serial number of the camera body. | |
| double | ShutterSpeedValue |
| Shutter speed (APEX value, reciprocal of exposure time). | |
| String | Software |
| Software used to create/modify the image. | |
| Buffer< uint16_t > | SubjectArea |
| Location and area of the main subject relative to upper-left origin. | |
| double | SubjectDistance |
| Distance to the focus point in meters. | |
| String | SubSecTimeOriginal |
| Sub-second time of original capture. | |
| double | XResolution |
| Number of pixels per ResolutionUnit in the X (width) direction. | |
| double | YResolution |
| Number of pixels per ResolutionUnit in the Y (height) direction. | |
Stores and parses EXIF and XMP metadata extracted from a JPEG image stream.
After construction or a call to one of the parseFrom() overloads, the public data members are populated with the metadata values found in the image. Use the Fields member to check which categories of data were successfully parsed.
Definition at line 68 of file TinyExif.h.
| EXIFInfo::EXIFInfo | ( | ) |
Default constructor.
Initializes all fields to their default (empty/zero) values.
| EXIFInfo::EXIFInfo | ( | EXIFStream & | stream | ) |
Constructs and immediately parses EXIF/XMP data from the given EXIFStream.
| [in] | stream | The stream interface providing JPEG image data. |
| EXIFInfo::EXIFInfo | ( | std::istream & | stream | ) |
Constructs and immediately parses EXIF/XMP data from a standard input stream.
| [in] | stream | A std::istream opened in binary mode containing a JPEG image. |
| EXIFInfo::EXIFInfo | ( | const uint8_t * | data, |
| unsigned | length ) |
Constructs and immediately parses EXIF/XMP data from a raw memory buffer.
| [in] | data | Pointer to the JPEG image data. |
| [in] | length | Size of the data buffer in bytes. |
| void EXIFInfo::clear | ( | ) |
Resets all data members to their default values.
Should be called before parsing a new stream to ensure stale data from a previous parse does not persist.
| int EXIFInfo::parseFrom | ( | const uint8_t * | data, |
| unsigned | length ) |
Parses EXIF and XMP metadata from a JPEG image in a raw memory buffer.
| [in] | data | Pointer to the JPEG image data. |
| [in] | length | Size of the data buffer in bytes. |
| int EXIFInfo::parseFrom | ( | EXIFStream & | stream | ) |
Parses EXIF and XMP metadata from a JPEG image provided via an EXIFStream.
| [in] | stream | The stream interface providing JPEG image data. |
| int EXIFInfo::parseFrom | ( | std::istream & | stream | ) |
Parses EXIF and XMP metadata from a JPEG image provided via a standard input stream.
| [in] | stream | A std::istream opened in binary mode containing a JPEG image. |
| int EXIFInfo::parseFromEXIFSegment | ( | const uint8_t * | buf, |
| unsigned | len ) |
Parses metadata from a standalone EXIF segment (blob starting with "Exif\0\0").
This is used internally by parseFrom() but can be called directly when only the EXIF segment is available.
| [in] | buf | Pointer to the EXIF segment data. |
| [in] | len | Size of the EXIF segment in bytes. |
| int EXIFInfo::parseFromXMPSegment | ( | const uint8_t * | buf, |
| unsigned | len ) |
Parses metadata from a standalone XMP segment.
The blob should start with "http://ns.adobe.com/xap/1.0/\0". Used internally by parseFrom() but can be called for special cases.
| [in] | buf | Pointer to the XMP segment data. |
| [in] | len | Size of the XMP segment in bytes. |
| int EXIFInfo::parseFromXMPSegmentXML | ( | const char * | szXML, |
| unsigned | len ) |
Parses metadata from raw XMP XML content.
| [in] | szXML | Pointer to the null-terminated XMP XML string. |
| [in] | len | Length of the XML string in bytes. |
| uint16_t EXIFInfo::ExposureProgram |
Exposure program used.
0: not defined, 1: manual, 2: normal program, 3: aperture priority, 4: shutter priority, 5: creative, 6: action, 7: portrait, 8: landscape
Definition at line 212 of file TinyExif.h.
| uint16_t EXIFInfo::Flash |
Flash status bitmask.
Bit 0: flash fired. Bits 1-2: return light status. Bits 3-4: flash mode. Bit 5: flash function present. Bit 6: red-eye reduction supported.
Definition at line 223 of file TinyExif.h.
| uint16_t EXIFInfo::LightSource |
Kind of light source.
0: unknown, 1: daylight, 2: fluorescent, 3: tungsten, 4: flash, 9-15: various daylight/fluorescent types, 17-23: standard lights A-C and D-series, 24: ISO studio tungsten
Definition at line 230 of file TinyExif.h.
| uint16_t EXIFInfo::MeteringMode |
Metering mode.
0: unknown, 1: average, 2: center weighted average, 3: spot, 4: multi-spot, 5: pattern, 6: partial
Definition at line 227 of file TinyExif.h.
| uint16_t EXIFInfo::Orientation |
Image orientation (EXIF tag 0x0112).
0: unspecified, 1: upper left, 3: lower right, 6: upper right, 8: lower left, 9: undefined
Definition at line 196 of file TinyExif.h.
| uint16_t EXIFInfo::ProjectionType |
Projection type.
0: unknown, 1: perspective, 2: equirectangular/spherical
Definition at line 234 of file TinyExif.h.
| uint16_t EXIFInfo::ResolutionUnit |
Unit of measurement for XResolution and YResolution.
1: no absolute unit, 2: inch, 3: centimeter
Definition at line 201 of file TinyExif.h.
| Buffer<uint16_t> EXIFInfo::SubjectArea |
Location and area of the main subject relative to upper-left origin.
2 values: XY coordinates; 3 values: circle (X, Y, diameter); 4 values: rectangle (X, Y, width, height)
Definition at line 236 of file TinyExif.h.