Using jhead for date manipulations

2015-09-20 jhead exif photo

Ways to update photo EXIF/IPTC properties.

For long time I am using Nikon DSLR cameras. When photos are downloaded to the computer sometimes it needs quick manipulate of its EXIF/IPTC data. There is handy (and very quick) tool jhead.

Simplest usage is to run it with name(s) of image files:

> jhead IMG_20190402_185759.jpg

File name    : IMG_20190402_185759.jpg
File size    : 3960547 bytes
File date    : 2019:04:02 17:58:00
Camera make  : HUAWEI
Camera model : HUAWEI TIT-L01
Date/Time    : 2019:04:02 18:57:59
Resolution   : 4160 x 3120
Flash used   : No
Focal length :  3.5mm
Exposure time: 0.060 s  (1/17)
Aperture     : f/2.0
ISO equiv.   : 507
Whitebalance : Auto
Metering Mode: center weight
GPS Latitude : N 49d 12m  0.7580s
GPS Longitude: E 16d 38m 26.6688s
GPS Altitude :  204.00m
JPEG Quality : 95

When I forget to shift the camera date/time for new timezone. This command will set all photos an hour earlier:

> jhead -ta-1 -ft **\*.jpg

Or when the camera’s datetime is set to something completely wrong, following command can adjust by large amount:

> jhead -da2015:09:05/20:32-2011:05:10/01:49 -ft **\*.jpg

If you already mixed photos from various sources (mobile, camera, etc) and want to modify just one of them, useful switch is -model that filters only images made by specific camera model. It works with any substring, like

> jhead -ta-1 -ft -model NIKON **\*.jpg