Set a watermark on an image, rotate, round corners and create a new image

Here's a simple extension that allows you to add a watermark to an image, rotate it, round corners, and create a new image in a subfolder of the ASD (.../Pictures/watermarked_image_1748174530410.jpg). Set the compression quality (1–100) in the Watermark and/or Rotate methods.

The RoundCorner method requires the new image to be saved as a PNG due to transparency. A PNG file cannot be compressed using conventional methods.Therefore, there is no "compressionQuality" parameter for the RoundCorner method. Determine the file size, etc. The image to be watermarked (rotated, rounded) can come from any location:

  • assets,
  • external storage,
  • ASD.

Of course, READ permissions are required for images from external storage that were not created by the app (READ_EXTERNAL_STORAGE for Android < 13 and READ_MEDIA_IMAGES for Android 13+).

Example blocks

Screenshots

4 Likes