Hi,
after reading about every post regarding this topic, I still couldn't find a hint how to solve my problem.
I shoot with my camera set to UTC and now want to re-write my timestamps like this:
(1) Create and populate GPSDateStamp and GPSTimeStamps tags from DateTimeOriginal (=UTC).
(2) Run ExifTool to re-write CreateDate and DateTimeOriginal with timezone adjustment (say +3 hours for UTC+3); add - like Phil suggested in an earlier post - the timezone appendix "+03:00" to both EXIF tags, even though this is not standard-compliant.
(3) Populate IPTC:DateCreated, IPTC:TimeCreated and XMP:CreateDate with the time-zoned values (+03:00).
I modified the .ExifTool_config file to create user variables for a set of UTC deviations:
%Image::ExifTool::UserDefined = (
'Image::ExifTool::Composite' => {
# Variable takes UTC from DateTimeOriginal
UTC => {
Require => 'DateTimeOriginal',
ValueConv => '$val',
},
# Variable takes UTC timestamp from camera and shifts timezone
UTCplus1 => {
Require => {
0 => 'DateTimeOriginal',
},
ValueConv => q{
require 'Image/ExifTool/Shift.pl';
# 'n' is the added timezone value, +1 is forward, -1 is back
Image::ExifTool::ShiftTime($val[0], '1', +1);
return $val[0];
},
PrintConv => '$self->ConvertDateTime($val)',
},
(etc.)
},
);
#------------------------------------------------------------------------------
1; #end
In order to modify my files, I use the following statement:
exiftool -n -overwrite_original '-GPSDateStamp<UTC' '-GPSTimeStamp<UTC' '-CreateDate<${UTCplus1}+01
+:00' '-DateTimeOriginal<${UTCplus1}+01:00' '-IPTC:DateCreated<UTCplus1' '-IPTC:TimeCreated<UTCplus
+1' DIR
Unfortunately, this doesn't do what I expected. It doesn't create the GPSDateTime tags, for instance. The tags I get as a result are
---- IPTC ----
Date Created : 2009:03:14
Time Created : 12:07:53+01:00
---- ExifIFD ----
Date/Time Original : 2009:03:14 12:07:53+01:00
Create Date : 2009:03:14 12:07:53+01:00
---- Composite ----
Date/Time Created : 2009:03:14 12:07:53+01:00
Date/Time Original : 2009:03:14 12:07:53+01:00.22
UTC : 2009:03:14 12:07:53+01:00
UT Cminus 1 : 2009:03:14 11:07:53+01:00
UT Cminus 10 : 2009:03:14 02:07:53+01:00
UT Cminus 11 : 2009:03:14 01:07:53+01:00
UT Cminus 12 : 2009:03:14 00:07:53+01:00
UT Cminus 2 : 2009:03:14 10:07:53+01:00
UT Cminus 3 : 2009:03:14 09:07:53+01:00
UT Cminus 4 : 2009:03:14 08:07:53+01:00
UT Cminus 5 : 2009:03:14 07:07:53+01:00
UT Cminus 6 : 2009:03:14 06:07:53+01:00
UT Cminus 7 : 2009:03:14 05:07:53+01:00
UT Cminus 8 : 2009:03:14 04:07:53+01:00
UT Cminus 9 : 2009:03:14 03:07:53+01:00
UT Cplus 1 : 2009:03:14 13:07:53+01:00
UT Cplus 10 : 2009:03:14 22:07:53+01:00
UT Cplus 11 : 2009:03:14 23:07:53+01:00
UT Cplus 12 : 2009:03:15 00:07:53+01:00
UT Cplus 2 : 2009:03:14 14:07:53+01:00
UT Cplus 3 : 2009:03:14 15:07:53+01:00
UT Cplus 4 : 2009:03:14 16:07:53+01:00
UT Cplus 5 : 2009:03:14 17:07:53+01:00
UT Cplus 6 : 2009:03:14 18:07:53+01:00
UT Cplus 7 : 2009:03:14 19:07:53+01:00
UT Cplus 8 : 2009:03:14 20:07:53+01:00
UT Cplus 9 : 2009:03:14 21:07:53+01:00
Any idea what I have missed?
Thanks,
Leo