ExifTool > The "exiftool" Application

Reading/Writing Custom EXIF tags w/o config file

(1/1)

benvolio:
I want to add UserDefined tags to a lot of JPEG files but would rather not carry the extra baggage of all the accompanying config files. My question is: Once I add the custom tags, can I delete the config file while still being able to access the tags? (In the exerpts below, the tag name "Month" is only accessible in the config file, while the accompanying value "May" is now written to APP1. Is there someway to have the tag, "Month", appear alongside the value, "May".)

Config file:

--- Code: ---%Image::ExifTool::UserDefined = (
   # All EXIF tags are added to the Main table, and WriteGroup is used to
   # specify where the tag is written (default is ExifIFD if not specified):
   'Image::ExifTool::Exif::Main' => {
     # Example 1.  EXIF:NewEXIFTag
     # 0xd000 =>
     #    Name => 'NewEXIFTag',
     #    Writable => 'int16u',
     #    WriteGroup => 'IFD0',
     # },
     # add more user-defined EXIF tags here...

        0xd001 => {
          Name => 'Month',
          Writable => 'string',
          WriteGroup => 'IFD0',
        },
    },
);
--- End code ---

Command Prompt call of "exiftool -v1 [image_file.jpg]":
| 4)  Exif_0xd001 = May

Thank you, in advance, for your help!

StarGeek:
Without the config file, exiftool will not display your custom tag without the -u option.  Even then, it will not display the name because EXIF tags do not have the name embedded in the file.  For example:
Exif_0xd001                     : may

I would suggest creating an XMP tag instead.  Exiftool will extract XMP tags it doesn't know with the name, though it will not be able to edit or copy without the config file.

I copy/pasted/edited this simple tag definition with this resulting config

--- Code: ---%Image::ExifTool::UserDefined = (
    'Image::ExifTool::XMP::xmp' => {
        # Month tag (simple string, no checking)
        Month => { },
    },
);
1;
--- End code ---

And example writing with config and then reading without config.

--- Code: ---C:\>exiftool -config xx.txt -P -overwrite_original -month=may y:\!temp\Test4.jpg
    1 image files updated

C:\>exiftool -g1 -a -s -month y:\!temp\Test4.jpg
---- XMP-xmp ----
Month                           : may
--- End code ---

benvolio:
Thanks for your help StarGeek!

Navigation

[0] Message Index

Go to full version