Skip to main
Table of Contents

Image Watermark

Below are images with watermarks that are applied that have watermark in their filename.

Demonstration

Single Layer

Multiple Layers

Configuration

The images above are watermarked based on the following configuration. Each rule defines the file pattern and one or more layers to apply. Images with `*.watermark_tile.*` filenames use a single watermark layer, while images with `*.watermark_logo.*` filenames use multiple layers.

{
  "image": {
    "watermark": [
      {
        "pattern": "**/*.watermark_tile.*",
        "layers": [
          {
            "image": "brand/_watermark_tile.png",
            "gravity": "Center",
            "dissolve": 37.5,
            "resize": "100%",
            "background": "none",
            "gmOptions": "-tile"
          }
        ]
      },
      {
        "pattern": "**/*.watermark_logo.*",
        "layers": [
          {
            "image": "brand/_watermark_tile.png",
            "gravity": "Center",
            "dissolve": 37.5,
            "resize": "100%",
            "background": "none",
            "gmOptions": "-tile"
          },
          {
            "image": "brand/_watermark_logo.png",
            "gravity": "SouthEast",
            "dissolve": 100,
            "resize": {
              "width": "50%t",
              "minWidth": "256px",
              "maxWidth": "100%t",
              "maxHeight": "10%t"
            },
            "background": "none"
          }
        ]
      }
    ]
  }
}

The gallery on this page is based on the PhotoSwipe JavaScript library. For more information, please see the Photo Gallery example page.