contours won’t solve this. too complex to achieve the same result as…
morphology operations. take the alpha channel (opacity mask), threshold it so any non-zero value becomes true/255, then dilate. structuring element (“kernel”) ought to be a nice big circle/ellipse.
first compose the picture onto white background, then apply the dilated mask to that.
I see that you already dilate the alpha channel… so you’re on the right track already. I don’t see why you’d involve contours then.