Page 1 of 1

Add background color clip path ImageMagick

Posted: Wed Feb 13, 2019 11:55 am
by ChritianK
Hi All,

I want to made a flow in order to add background color on image with path to check quality of it.

Image is in jpeg format with vector path named "DET"
Don't know if the -clip-path "DET" is the good choice to select the right path named "DET", and didn't know after that how to change background color,
maybe this :
-background "#448646" to have a green background color.

This flow would be interesting for me to check if the path made on images are nice or not, so it could be viewed in browser for example without needed to open images in Photoshop and select the path, convert to mask etc....

Best Regards,
Christian

Re: Add background color clip path ImageMagick

Posted: Wed Feb 13, 2019 12:14 pm
by jan_suhr
The clipping path in Image Magick lacks antialiasing making the clipping jagged. If you can live with that.

There is another program that can run with IM that smooth the clipping path for a proper look, it only works on Windows, check in the Image Magick forum there is a lot of info on it there.

Re: Add background color clip path ImageMagick

Posted: Thu Feb 28, 2019 4:32 pm
by ChritianK
Hi Jan,

I founded effectively, it works better with Inkscape, have to export the clipping path within ImageMagick and convert with Inkscape.
Result seems to be like photoshop.

Re: Add background color clip path ImageMagick

Posted: Thu Feb 28, 2019 4:37 pm
by jan_suhr
Yes it was Inkscape I was thinking of