Great, I've made some progress... ...and sorry for my hopeless lack of understanding of bitmap manipulation.
In my (PerlMagick) script I now make a new image with a transparent background of the same dimensions and then blur it. Then I Composite it onto the original image. Right now I'm using the Screen composite method which seems to get closest to the result.
Actually, I've been looking around the examples pages some more and it looks like the stuff
here is really close to the result I want to achieve anyway. That is to say, I want to make an image that is (already) on a transparent background to get a 'nice edge' so that it can be placed on a 'noisy background' and still stand out. The specific example on the examples page starts out with an image on a white background (i.e. no transparent layer). So would I be close with something like the following sequence?
- convert myImageWithTransparentBackground.png <some command to extract the alpha mask> difference.png
- convert difference.png -bordercolor black -border 5 -threshold 10% -blur 0x3 halo_mask.png
- convert myImageWithTransparentBackground.png -bordercolor white -border 5 halo_mask.png +matte -compose CopyOpacity -composite myImageWithTransparentBackgroundAndHalo.png