Page 1 of 1

How can I replace the color #234567 by the color #223344?

Posted: 2008-03-16T04:48:41-07:00
by bensto
How can I replace the color #234567 in all pixels by the color #223344 ?

As the subject already said I am searching for a way to replace all pixels with the color #234567
in a currently existing picture with the color #223344.

How can I do this with IM?

Ben

Re: How can I replace the color #234567 by the color #223344?

Posted: 2008-03-16T08:27:04-07:00
by rmagick
Use the -opaque option for the convert command.

Re: How can I replace the color #234567 by the color #223344?

Posted: 2008-03-21T07:12:18-07:00
by bensto
rmagick wrote:Use the -opaque option for the convert command.
...and how would the full command line look like?

Ben

Re: How can I replace the color #234567 by the color #223344?

Posted: 2008-03-21T12:08:29-07:00
by fmw42
convert <infile> -fill "#223347" -opaque "#234567" <outfile>

see
http://www.imagemagick.org/Usage/color/#replace