Outline Contour
Posted: 2016-09-13T04:26:26-07:00
Hi!
I'm trying to add a slight contour to the outline/silhouette of one image.
What I would like would be to:
1. take the exterior pixels
I've tried with
2. darken/saturate the exterior
3. dilate the exterior by 1-2 pixels (but I think 1 pixel is enough???) keeping the colors, then apply some transparency to this thin contour.
The problem is I'm not sure how to do that? I need some help here.
4. compose the final image by overlaying the saturated contour and the dilated contour over the original image.
Thanks!
I'm trying to add a slight contour to the outline/silhouette of one image.
What I would like would be to:
1. take the exterior pixels
I've tried with
Code: Select all
convert input.png ^
-channel A -virtual-pixel transparent ^
-morphology EdgeIn Diamond ^
strokedOutMorph.png
Code: Select all
convert strokedOutMorph.png ^
-colorspace HSL -channel Saturation -negate -evaluate multiply 0.8 -negate -colorspace RGB ^
strokedOutMorph_saturated.png
The problem is I'm not sure how to do that? I need some help here.
4. compose the final image by overlaying the saturated contour and the dilated contour over the original image.
Thanks!