Date and timezone in videos

Started by Widescreen, April 23, 2019, 05:09:42 AM

Previous topic - Next topic

Widescreen

Hi everyone, and thanks Mr Harvey for this awesome program.

I am struggling with the timezone value after dates. Is there nay way to change it?

This is the reason:
I have successfully copied the FileModifyDate value to CreateDate in some m4v videos:
exiftool "-FileModifyDate>CreateDate" -P DIR
With those m4v the timezone value was not copied from the one in FileModifyDate. Just the time and date. I then shifted the time to put it in UTC like it should. Good.
But when I ran the same command with .mov files taken with an action cam, the timezone info from FileModifyDate was actually copied in the CreateDate tag. Despite this it looks like Google Photos is not taking this information into account. So I have to put it in UTC too. So I end up with an UTC time and a wrong timezone value. I'm concerned that at some point Google Photos or any other program might use this information and shift the time accordingly.
Hence my question: is there a way to remove the timezone value appended in the CreateDate tag (or any other tag), or at least to set it to +00:00 to avoid any future problem and remain consistent across my files?

Hope this is clear, thanks for the help!

Hayo Baan

Since you want the times to be UTC, you might find adding -api QuickTimeUTC=1 to the command solves your problem.

Background: the QuickTime spec stipulates that QuickTime dates should be UTC. Many cameras, however, use the local time instead. Because of this exiftool by default assumes the times are local, even though this is incorrect according to the spec. By adding -api QuickTimeUTC=1 you are again telling exiftool to adhere to the standard.

Hope this helps,
Hayo
Hayo Baan – Photography
Web: www.hayobaan.nl

Widescreen

Thanks! I will try this.
Alternatively is there a command that can change a date from:
2019:04:23 14:00:00+02:00
To:
2019:04:23 14:00:00
Or:
2019:04:23 14:00:00+00:00

Thanks!

StarGeek

To just remove the time zone and not shift the time?

To remove the time zone if it is already in the file
exiftool -P -d "%Y:%m:%d %H:%M:%S" -TagsFromFile @ -CreateDate FileOrDir

To use in your original command
exiftool "-FileModifyDate>CreateDate" -P -d "%Y:%m:%d %H:%M:%S" DIR
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

Phil Harvey

Note that some QuickTime date/time tags will always show the system time zone if -api quicktimeutc is used.  With these, the only way to remove the time zone is to not use the QuickTimeUTC option, and the only way to change the timezone when QuickTimeUTC is used is to change the system time zone.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

Widescreen