Page 1 of 1

Insert exif data during convert

Posted: 2018-07-17T05:58:59-07:00
by rogierl
I have the following convert cmd which I use to resize a lot of images. I make use of the - strip command, but I do want to add one specific exif attribute ("copyright"). Is this possible? I know I can use exiftool for this, but isn't this possible in "one call" to the convert tool?
convert -type TrueColorAlpha \
-colorspace sRGB \
-define tiff:ignore-layers=true \
-fuzz 1000 \
-trim +repage \
-background red \
-alpha remove \
-resize 125x200 \
-filter lanczos2 \
-type TrueColor \
-colorspace sRGB \
-sampling-factor 4:2:0 \
-interlace none \
-quality 90 \
-density 72x72 \
-strip \
input.png \
output.jpg

Re: Insert exif data during convert

Posted: 2018-07-17T09:08:29-07:00
by fmw42
No, as far as I know ImageMagick does not write EXIF data to a file. It should pass existing information on, but will not write new EXIF data to a file. You may write that information into the comment field or the label field via -set comment or -set label. Otherwise, as you noted, you can use EXIFTOOL.