Challenge
When you add a watermark to an image file stored in an Alibaba Cloud Object Storage Service (OSS), the watermark does not take effect.
Cause
An image watermark does not support the transparent image layer of the original image. When adding a watermark, the watermark image is fused into the RGB channel with the color of the original image as the background color. The Alpha channel retains the initial value. The Alpha channel has only two values (fully transparent or opaque), resulting in invisible effects after the watermark is added.
Modification method
JPG and PNG are two different image formats. JPG images have no transparent background, while PNG images can retain transparent background. Check whether the original image is in PNG format. If it is in PNG format, convert it to JPG format first and then add a watermark. For more information, see Format conversion.
Applicable scope
- Object Storage Service (OSS)