Watermark photographs with filenames

Discussion in 'Digital Photography' started by jmbill, Apr 17, 2009.

  1. jmbill macrumors member

    Joined:
    Dec 17, 2008
    #1
    I've got a large folder of photographs which I want to batch-watermark. I want to batch-watermark each image with its filename e.g "image_01.jpg" for easy reference.

    I thought this would be really easy to do, but after searching the internet and various forums, I have not been able to find a solution. I thought this would be a perfect job for Automator, but after a few hours of trying it seems this is beyond the ability of Automator. I already own a copy of iWatermark, but this has no option for what I want to do. I do not own Photoshop CS, but I do have Photoshop Elements 4, and Pixelmator, plus a few other basic editing applications.

    Does anyone know of a basic freeware application or script that can do what I'm looking to do?
     
  2. ChrisA macrumors G4

    Joined:
    Jan 5, 2006
    Location:
    Redondo Beach, California
    #2
    Take a look at Imagemagick. It's a command line image editor, very scripable with either Perl or shell
    http://www.imagemagick.org/
     
  3. EugeneA macrumors newbie

    Joined:
    Feb 1, 2008
    #3
    Try ImageMagick, if you are brave...

    If you are not afraid of command line, you can use ImageMagick
    to do what you want:

    First, install macport from www.macports.org.
    Once Macport is installed, open a terminal and install ImageMagick:

    sudo port install ImageMagick

    It will take a bit of time....

    And now you are ready for images:

    In the directory with images, type:

    for nm in *.JPG *.jpg; do mogrify -fill white -pointsize 50 -draw "text 0,50 $nm" $nm; done

    Remember, this will modify your images in place! Make a backup before experimenting, or use convert instead of mogrify!

    Modify the options to mogrify to suit your taste. You can do just about anything with your images with this toolkit.

    Check out http://www.imagemagick.org for documentation
    on ImageMagick. It's super powerful toolkit for batch manipulation of images. I use it all the time.

    Attached is an example of running this script. It's just a starting point, play with the options to get better font, color, text location etc.
     

    Attached Files:

    • iris.jpg
      iris.jpg
      File size:
      81.7 KB
      Views:
      108
  4. jmbill thread starter macrumors member

    Joined:
    Dec 17, 2008
    #4
    I've installed MacPorts and Installed ImageMagick via Terminal.

    What I'm doing is dragging the folder named 'images_to_watermark' from my Desktop into a new Terminal window to create the path to the directory. Then I am pasting or manually typing your code after the directory address and hitting return.

    But I'm getting a "-bash: syntax error near unexpected token `do' " error in Terminal and the images are not being processed.

    Any ideas?
     

    Attached Files:

  5. EugeneA macrumors newbie

    Joined:
    Feb 1, 2008
    #5
    ImageMagick

    You need to change into the directory with images before running my commands. Type "cd" in the terminal and then drag the directory into the terminal. Press "return" and it should change to the directory with images. After that try the commands. But remember that images will be changed in place. Please, please, please back them up before trying.
    See the image below. You can safely ignore the error about *.JPG, all images I have are *.jpg.
     

    Attached Files:

  6. jmbill thread starter macrumors member

    Joined:
    Dec 17, 2008
    #6
    Thanks - works perfectly! As you can tell, I'm still a bit of a learner when it comes to Terminal, but this will be something else I can add to the "I can do this in Terminal" list! :)
     

Share This Page