Shortcut Recipe: Add logos or stickers to selected photos

This delicious recipe allows the user to:

  • select one or more photos, then
  • select from a set of PNG logos to apply on top of each photo in turn

Repositioning, scaling and rotating the logo is allowed, and PNG transparency is maintained.

Ingredients:

  • a folder of logos in .png format with transparency
    • folder must be under /shortcuts/ in iCloud
  • a list of the logos as a .json file in the same folder
    • key: natural language title
    • value: filename

Actions:

  1. select photos from photo library or camera
  2. get the .json file as a static path
  3. get dictionary from the file
  4. list the dictionary keys
  5. choose from list of keys
  6. get the value of the selected key from the dictionary
  7. get the file by appending the dictionary value to the folder path
  8. overlay the the file on the selected photo (Media > overlay action)
  9. adjust size, position, angle, of logo as required

At this point the image(s) can be saved or posted to social media, etc.

The reason logos are stored outside the Photo library is because PNGs selected from the photo library are flattened when applied by the “overlay” action, losing the transparency.

The reason for listing the files as json is because it’s easier to update and edit a json file than using a dictionary in Shortcuts, plus it’s available to use elsewhere if needed. It could of course be a normal dictionary.

For “logos” read any .png with transparency which you need to apply to a photo, such as watermark, flash, cartoon slam, etc.

Comments welcome.

This is great! I made a similar shortcut by encoding the png as Base64. Thanks for sharing.