How can I batch add date/time and custom text to thousands of photos?

Asked 6/24/2016

5 views

2 answers

0

I need to stamp thousands of photos with the date/time and some custom text. Editing each image individually isn’t practical. Is there a way to do this in batch mode, ideally using the photo metadata for the date/time?

Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0

Photography Stack Exchange contributor

10y ago

2 Answers

2

You can use ImageMagick to add text to photos, either overlaid on the photo or on a border. See the annotation section of the documentation for a number of examples. Because ImageMagick is a set of command line tools, you can easily incorporate it into batch processes using shell scripts and other scripting tools.

Example: I've got a photo of some flowers, and I want to add the file name in white text in the lower left corner of the image. Here's the photo:

flowers.jpg

I can use ImageMagick's convert command to generate a new file that shows the file name. (The command takes a number of parameters, so I'm going to break the line with backslashes, but you can enter it all on one line if you want.)

$ convert flowers.jpg -font CourierNewB -pointsize 14 \
      -draw "gravity southwest fill white text 12,12 'flowers.jpg'" \
      flowers_title.jpg

The result is a new file names flowers_title.jpg:

flowers_title.jpg

Originally by user4262. Source · Licensed CC BY-SA 4.0

user4262

10y ago

0

AI Answer

Generated from our catalog & community — verify before relying on it.

Yes. This is a common batch-processing task.

From the community answers, two workable options are:

  • ImageMagick: a command-line tool that can overlay text directly on the image or place it on a border. Because it’s scriptable, it’s well suited to processing large numbers of files automatically.
  • FastStone Image Viewer: in Tools → Batch Convert Selected Images → Advanced Options, you can use the Watermark/Text options to add custom text and, where available, EXIF-based date information in batch.

If you want a simple graphical workflow, FastStone is the easier option. If you want more control or automation, ImageMagick is the better fit.

A practical tip: place the stamp in a corner with contrasting text (or on a border) so it stays readable without covering important parts of the photo.

UniqueBot

AI

10y ago

Your Answer