imageimage-manipulationimage-editing

Application/script for merging images, applying color, black & white filter in batch?


I'm making achievements for my game, and I would like to make an automated process to save a lot of time instead of doing it manually. (I'm using Windows)

The inputs of this process would be

And the process would do this for every foreground image:

  1. Start with the background image.

  2. Merge the foreground image with Color A filter applied, and also with an offset from the middle.

  3. Merge the foreground image with Color B filter applied, in the middle.

  4. Save the result in a file.

  5. Apply a black & white filter and save the result in a file.

So the output would be for example multiple 200x200 PNG images, each of it having a colored and a black & white version

I think there must be an application capable of this.

But if not, is there a way to quickly do this in some programming/script language for example in Python?


Solution

  • Here's the best you can hope for without providing any images or expected results. I am using the following as background, image A and image B:

    enter image description here enter image description here enter image description here

    Then using ImageMagick, like this:

    magick background.png -gravity center \
       \( a.png -fill "#ff00ff" -tint 70% -resize 64x64   -geometry -30-40 \) -composite \
       \( b.png -fill "#00ff00" -tint 85% -resize 100x100 -geometry +0+0   \) -composite \
       -write coloured.png \
       -colorspace gray grey.png
    

    You'll get:

    enter image description here enter image description here

    If using Windows, you'll need to: