I want to make all pixels of a certain #RGB white/black in an image or the inverse rendering all other pixels black. What is the best way to achieve that?
for example I want the image to only show pixels with RGB value of #002865
Thanks
_____________
website
Filter RGB Colors
-
- Posts: 1
- Joined: 2014-04-05T11:38:38-07:00
- Authentication code: 6789
Filter RGB Colors
Last edited by TPMarketing on 2014-04-07T09:14:16-07:00, edited 1 time in total.
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Filter RGB Colors
Code: Select all
convert image -fuzz XX% -fill "#002865" +opaque black result
If you want to change #002865 to white and the rest black, then
Code: Select all
convert image -fuzz XX% -fill "#002865" -opaque white +opaque black result
http://www.imagemagick.org/Usage/color_basics/#replace