Go to the documentation of this file.
   31 #define EXIF_TAG_NAME_LENGTH   32 
   39     {
"GPSVersionID",               0x00}, 
 
   40     {
"GPSLatitudeRef",             0x01},
 
   41     {
"GPSLatitude",                0x02},
 
   42     {
"GPSLongitudeRef",            0x03},
 
   43     {
"GPSLongitude",               0x04},
 
   44     {
"GPSAltitudeRef",             0x05},
 
   45     {
"GPSAltitude",                0x06},
 
   46     {
"GPSTimeStamp",               0x07},
 
   47     {
"GPSSatellites",              0x08},
 
   49     {
"GPSMeasureMode",             0x0A},
 
   51     {
"GPSSpeedRef",                0x0C},
 
   53     {
"GPSTrackRef",                0x0E},
 
   55     {
"GPSImgDirectionRef",         0x10},
 
   56     {
"GPSImgDirection",            0x11},
 
   57     {
"GPSMapDatum",                0x12},
 
   58     {
"GPSDestLatitudeRef",         0x13},
 
   59     {
"GPSDestLatitude",            0x14},
 
   60     {
"GPSDestLongitudeRef",        0x15},
 
   61     {
"GPSDestLongitude",           0x16},
 
   62     {
"GPSDestBearingRef",          0x17},
 
   63     {
"GPSDestBearing",             0x18},
 
   64     {
"GPSDestDistanceRef",         0x19},
 
   65     {
"GPSDestDistance",            0x1A},
 
   66     {
"GPSProcessingMethod",        0x1B},
 
   67     {
"GPSAreaInformation",         0x1C},
 
   68     {
"GPSDateStamp",               0x1D},
 
   69     {
"GPSDifferential",            0x1E},
 
   70     {
"ImageWidth",                 0x100}, 
 
   71     {
"ImageLength",                0x101},
 
   72     {
"BitsPerSample",              0x102},
 
   73     {
"Compression",                0x103},
 
   74     {
"PhotometricInterpretation",  0x106},
 
   75     {
"Orientation",                0x112},
 
   76     {
"SamplesPerPixel",            0x115},
 
   77     {
"PlanarConfiguration",        0x11C},
 
   78     {
"YCbCrSubSampling",           0x212},
 
   79     {
"YCbCrPositioning",           0x213},
 
   80     {
"XResolution",                0x11A},
 
   81     {
"YResolution",                0x11B},
 
   82     {
"ResolutionUnit",             0x128},
 
   83     {
"StripOffsets",               0x111},
 
   84     {
"RowsPerStrip",               0x116},
 
   85     {
"StripByteCounts",            0x117},
 
   86     {
"JPEGInterchangeFormat",      0x201},
 
   87     {
"JPEGInterchangeFormatLength",0x202},
 
   88     {
"TransferFunction",           0x12D},
 
   89     {
"WhitePoint",                 0x13E},
 
   90     {
"PrimaryChromaticities",      0x13F},
 
   91     {
"YCbCrCoefficients",          0x211},
 
   92     {
"ReferenceBlackWhite",        0x214},
 
   94     {
"ImageDescription",           0x10E},
 
   99     {
"Copyright",                  0x8298},
 
  100     {
"ExifVersion",                0x9000}, 
 
  101     {
"FlashpixVersion",            0xA000},
 
  102     {
"ColorSpace",                 0xA001},
 
  103     {
"ComponentsConfiguration",    0x9101},
 
  104     {
"CompressedBitsPerPixel",     0x9102},
 
  105     {
"PixelXDimension",            0xA002},
 
  106     {
"PixelYDimension",            0xA003},
 
  107     {
"MakerNote",                  0x927C},
 
  108     {
"UserComment",                0x9286},
 
  109     {
"RelatedSoundFile",           0xA004},
 
  110     {
"DateTimeOriginal",           0x9003},
 
  111     {
"DateTimeDigitized",          0x9004},
 
  112     {
"SubSecTime",                 0x9290},
 
  113     {
"SubSecTimeOriginal",         0x9291},
 
  114     {
"SubSecTimeDigitized",        0x9292},
 
  115     {
"ImageUniqueID",              0xA420},
 
  116     {
"ExposureTime",               0x829A}, 
 
  118     {
"ExposureProgram",            0x8822},
 
  119     {
"SpectralSensitivity",        0x8824},
 
  120     {
"ISOSpeedRatings",            0x8827},
 
  122     {
"ShutterSpeedValue",          0x9201},
 
  123     {
"ApertureValue",              0x9202},
 
  124     {
"BrightnessValue",            0x9203},
 
  125     {
"ExposureBiasValue",          0x9204},
 
  126     {
"MaxApertureValue",           0x9205},
 
  127     {
"SubjectDistance",            0x9206},
 
  128     {
"MeteringMode",               0x9207},
 
  129     {
"LightSource",                0x9208},
 
  131     {
"FocalLength",                0x920A},
 
  132     {
"SubjectArea",                0x9214},
 
  133     {
"FlashEnergy",                0xA20B},
 
  134     {
"SpatialFrequencyResponse",   0xA20C},
 
  135     {
"FocalPlaneXResolution",      0xA20E},
 
  136     {
"FocalPlaneYResolution",      0xA20F},
 
  137     {
"FocalPlaneResolutionUnit",   0xA210},
 
  138     {
"SubjectLocation",            0xA214},
 
  139     {
"ExposureIndex",              0xA215},
 
  140     {
"SensingMethod",              0xA217},
 
  141     {
"FileSource",                 0xA300},
 
  142     {
"SceneType",                  0xA301},
 
  143     {
"CFAPattern",                 0xA302},
 
  144     {
"CustomRendered",             0xA401},
 
  145     {
"ExposureMode",               0xA402},
 
  146     {
"WhiteBalance",               0xA403},
 
  147     {
"DigitalZoomRatio",           0xA404},
 
  148     {
"FocalLengthIn35mmFilm",      0xA405},
 
  149     {
"SceneCaptureType",           0xA406},
 
  150     {
"GainControl",                0xA407},
 
  151     {
"Contrast",                   0xA408},
 
  152     {
"Saturation",                 0xA409},
 
  153     {
"Sharpness",                  0xA40A},
 
  154     {
"DeviceSettingDescription",   0xA40B},
 
  155     {
"SubjectDistanceRange",       0xA40C}
 
  173                              const char *
name, 
const char *sep,
 
  180                "Invalid TIFF tag type 0 found for %s with size %d\n",
 
  230             snprintf(buf, 
sizeof(buf), 
"0x%04X", 
id);
 
  234                                 gbytes, le, metadata);
 
  255     for (
i = 0; 
i < entries; 
i++) {
 
  
int ff_tadd_string_metadata(int count, const char *name, GetByteContext *gb, int le, AVDictionary **metadata)
Adds a string of count characters into the metadata dictionary.
 
TiffTypes
data type identifiers for TIFF tags
 
#define AV_LOG_WARNING
Something somehow does not look correct.
 
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf default minimum maximum flags name is the option name
 
static const char * exif_get_tag_name(uint16_t id)
 
static av_always_inline int bytestream2_seek(GetByteContext *g, int offset, int whence)
 
int avpriv_exif_decode_ifd(void *logctx, const uint8_t *buf, int size, int le, int depth, AVDictionary **metadata)
Recursively decodes all IFD's and adds included TAGS into the metadata dictionary.
 
int ff_tadd_rational_metadata(int count, const char *name, const char *sep, GetByteContext *gb, int le, AVDictionary **metadata)
Adds count rationals converted to a string into the metadata dictionary.
 
int ff_tadd_long_metadata(int count, const char *name, const char *sep, GetByteContext *gb, int le, AVDictionary **metadata)
Adds count longs converted to a string into the metadata dictionary.
 
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf type
 
int ff_exif_decode_ifd(void *logctx, GetByteContext *gbytes, int le, int depth, AVDictionary **metadata)
 
#define FF_ARRAY_ELEMS(a)
 
static int exif_decode_tag(void *logctx, GetByteContext *gbytes, int le, int depth, AVDictionary **metadata)
 
int ff_tadd_shorts_metadata(int count, const char *name, const char *sep, GetByteContext *gb, int le, int is_signed, AVDictionary **metadata)
Adds count shorts converted to a string into the metadata dictionary.
 
char name[EXIF_TAG_NAME_LENGTH]
 
unsigned ff_tget_short(GetByteContext *gb, int le)
Reads a short from the bytestream using given endianness.
 
static av_always_inline int bytestream2_get_bytes_left(GetByteContext *g)
 
static av_always_inline int bytestream2_tell(GetByteContext *g)
 
int ff_tread_tag(GetByteContext *gb, int le, unsigned *tag, unsigned *type, unsigned *count, int *next)
Reads the first 3 fields of a TIFF tag, which are the tag id, the tag type and the count of values fo...
 
int ff_tis_ifd(unsigned tag)
Returns a value > 0 if the tag is a known IFD-tag.
 
#define i(width, name, range_min, range_max)
 
unsigned ff_tget_long(GetByteContext *gb, int le)
Reads a long from the bytestream using given endianness.
 
#define EXIF_TAG_NAME_LENGTH
 
static int exif_add_metadata(void *logctx, int count, int type, const char *name, const char *sep, GetByteContext *gb, int le, AVDictionary **metadata)
 
static const struct exif_tag tag_list[]
 
#define avpriv_request_sample(...)
 
int ff_tadd_doubles_metadata(int count, const char *name, const char *sep, GetByteContext *gb, int le, AVDictionary **metadata)
Adds count doubles converted to a string into the metadata dictionary.
 
static av_always_inline void bytestream2_init(GetByteContext *g, const uint8_t *buf, int buf_size)
 
int ff_tadd_bytes_metadata(int count, const char *name, const char *sep, GetByteContext *gb, int le, int is_signed, AVDictionary **metadata)
Adds count bytes converted to a string into the metadata dictionary.
 
#define AVERROR_INVALIDDATA
Invalid data found when processing input.