How to create a transparent gradient along the edge of an image/mask image with python?
问题 Basically I want to create of a halo effect for the image that fades to transparent. I have images of wounds (and their masks), with no background. I want to add a red gradient behind it, that way if I paste it on something it looks like the area surrounded the wound is irritated. image and mask ... Originally, I was making a radial (circle) gradient and pasted my transparent image on it, but this does not look good for my non circular images. image with circle gradient same image as above