3#include <NDEVR/String.h>
51 virtual const uint8_t*
GetBuffer(
unsigned desiredLength) = 0;
92 EXIFInfo(
const uint8_t* data,
unsigned length);
127#ifndef TINYEXIF_NO_XMP_SUPPORT
166 void parseIFDImage(EntryParser&,
unsigned&,
unsigned&);
172 void parseIFDExif(EntryParser&);
178 void parseIFDGPS(EntryParser&);
184 void parseIFDMakerNote(EntryParser&);
The equivelent of std::vector but with a bit more control.
uint16_t LightSource
Kind of light source.
String DateTimeOriginal
Original capture date and time (may not exist).
EXIFInfo(const uint8_t *data, unsigned length)
Constructs and immediately parses EXIF/XMP data from a raw memory buffer.
double ShutterSpeedValue
Shutter speed (APEX value, reciprocal of exposure time).
int parseFromXMPSegmentXML(const char *szXML, unsigned len)
Parses metadata from raw XMP XML content.
double ExposureTime
Exposure time in seconds.
double YResolution
Number of pixels per ResolutionUnit in the Y (height) direction.
String ImageDescription
Image description.
String Model
Camera model.
int parseFromEXIFSegment(const uint8_t *buf, unsigned len)
Parses metadata from a standalone EXIF segment (blob starting with "Exif\0\0").
uint16_t Orientation
Image orientation (EXIF tag 0x0112).
EXIFInfo(std::istream &stream)
Constructs and immediately parses EXIF/XMP data from a standard input stream.
uint32_t Fields
Bitmask of FieldCode values indicating which metadata categories are available.
uint16_t ProjectionType
Projection type.
String DateTime
File change date and time.
String Copyright
File copyright information.
double BrightnessValue
Brightness value (APEX).
double SubjectDistance
Distance to the focus point in meters.
String DateTimeDigitized
Digitization date and time (may not exist).
uint32_t RelatedImageHeight
Original image height reported in EXIF data (pixels).
double ExposureBiasValue
Exposure bias value in EV.
String Software
Software used to create/modify the image.
uint32_t ImageHeight
Image height reported in EXIF data (pixels).
uint16_t Flash
Flash status bitmask.
double FocalLength
Focal length of the lens in millimeters.
EXIFInfo()
Default constructor.
String SubSecTimeOriginal
Sub-second time of original capture.
void clear()
Resets all data members to their default values.
uint16_t ExposureProgram
Exposure program used.
uint16_t ISOSpeedRatings
ISO speed rating.
double FNumber
F-number (f-stop) of the lens.
double XResolution
Number of pixels per ResolutionUnit in the X (width) direction.
Buffer< uint16_t > SubjectArea
Location and area of the main subject relative to upper-left origin.
String SerialNumber
Serial number of the camera body.
uint16_t ResolutionUnit
Unit of measurement for XResolution and YResolution.
String Make
Camera manufacturer's name.
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.
double ApertureValue
Lens aperture (APEX value).
uint16_t MeteringMode
Metering mode.
EXIFInfo(EXIFStream &stream)
Constructs and immediately parses EXIF/XMP data from the given EXIFStream.
int parseFromXMPSegment(const uint8_t *buf, unsigned len)
Parses metadata from a standalone XMP segment.
uint32_t ImageWidth
Image width reported in EXIF data (pixels).
int parseFrom(const uint8_t *data, unsigned length)
Parses EXIF and XMP metadata from a JPEG image in a raw memory buffer.
uint32_t RelatedImageWidth
Original image width reported in EXIF data (pixels).
uint16_t BitsPerSample
Number of bits per component.
Abstract interface for providing a stream of bytes to the EXIF parser.
virtual const uint8_t * GetBuffer(unsigned desiredLength)=0
Returns a pointer to a contiguous buffer of the requested size at the current position.
virtual bool IsValid() const =0
Checks whether the stream is in a valid, readable state.
virtual bool SkipBuffer(unsigned desiredLength)=0
Advances the current stream position by the specified number of bytes.
The core String class for the NDEVR API.
The primary namespace for the NDEVR SDK.
FieldCode
Bit flags indicating which metadata fields are available after parsing.
@ FIELD_ALL
Both EXIF and XMP data available.
@ FIELD_XMP
XMP data available.
@ FIELD_EXIF
EXIF data available.
@ FIELD_NA
No EXIF or XMP data.
ErrorCode
Error codes returned by EXIF/XMP parsing functions.
@ PARSE_UNKNOWN_BYTEALIGN
Byte alignment specified in EXIF file was unknown (neither Motorola nor Intel).
@ PARSE_ABSENT_DATA
No EXIF and/or XMP data found in JPEG file.
@ PARSE_SUCCESS
Parse EXIF and/or XMP was successful.
@ PARSE_CORRUPT_DATA
EXIF and/or XMP header was found, but data was corrupted.
@ PARSE_INVALID_JPEG
No JPEG markers found in buffer, possibly invalid JPEG file.
Camera calibration information derived from EXIF metadata.
double OpticalCenterY
Principal point Y coordinate in pixels.
double FocalLength
Focal length in pixels.
double OpticalCenterX
Principal point X coordinate in pixels.
Google Photo Sphere (GPano) spherical metadata.
double PosePitchDegrees
Pitch in degrees above the horizon for the image center. Range: [-90, 90].
bool hasPosePitchDegrees() const
Checks whether PosePitchDegrees contains a valid value.
double PoseRollDegrees
Roll in degrees; 0 is level with horizon, positive rotates horizon counterclockwise....
bool hasPoseRollDegrees() const
Checks whether PoseRollDegrees contains a valid value.
Geographic coordinate expressed in degrees, minutes, and seconds.
double degrees
Degrees component.
double minutes
Minutes component.
uint8_t direction
Cardinal direction character (e.g., 'N', 'S', 'E', 'W').
double seconds
Seconds component.
GPS and flight telemetry information embedded in the image file.
double SpeedZ
Flight speed along Z axis in meters/second.
String GPSDateStamp
Date as UTC in YYYY:MM:DD format (may not exist).
int8_t AltitudeRef
Altitude reference: 0 = above sea level, -1 = below sea level.
double PitchDegree
Flight pitch in degrees.
double RollDegree
Flight roll in degrees.
double YawDegree
Flight yaw in degrees.
double Latitude
Image latitude expressed as decimal degrees.
bool hasSpeed() const
Checks whether speed data is available.
double Altitude
Altitude in meters, relative to sea level.
double RelativeAltitude
Relative altitude in meters.
bool hasAltitude() const
Checks whether altitude data is available.
bool hasRelativeAltitude() const
Checks whether relative altitude data is available.
void parseCoords()
Converts Latitude/Longitude from degrees/minutes/seconds to decimal degrees.
uint16_t GPSDifferential
Differential correction applied to GPS receiver (may not exist).
struct EXIFInfo::Geolocation_t::Coord_t LonComponents
Longitude in degrees/minutes/seconds.
double Longitude
Image longitude expressed as decimal degrees.
double SpeedX
Flight speed along X axis in meters/second.
String GPSTimeStamp
Time as UTC (may not exist).
double SpeedY
Flight speed along Y axis in meters/second.
bool hasOrientation() const
Checks whether orientation (roll, yaw, pitch) data is available.
double GPSDOP
GPS dilution of precision (DOP).
bool hasLatLon() const
Checks whether latitude and longitude data are available.
double AccuracyXY
GPS horizontal accuracy in meters.
double AccuracyZ
GPS vertical accuracy in meters.
String GPSMapDatum
Geodetic survey datum (may not exist).
Lens information extracted from EXIF metadata.
double FocalLengthMax
Maximum focal length in millimeters.
String Make
Lens manufacturer.
double FStopMin
Minimum aperture (f-stop).
double FocalLengthMin
Minimum focal length in millimeters.
double FocalPlaneYResolution
Pixels per FocalPlaneResolutionUnit in Y direction (may not exist).
double DigitalZoomRatio
Digital zoom ratio when the image was shot.
double FocalPlaneXResolution
Pixels per FocalPlaneResolutionUnit in X direction (may not exist).
double FocalLengthIn35mm
Equivalent focal length in 35mm film.
uint16_t FocalPlaneResolutionUnit
Unit for FocalPlaneXResolution/YResolution.
double FStopMax
Maximum aperture (f-stop).
Google camera micro-video metadata embedded in the image file.
uint32_t HasMicroVideo
Non-zero if a micro-video is present.
uint32_t MicroVideoOffset
Byte offset of the micro-video from the end of the file.
uint32_t MicroVideoVersion
Micro-video format version.