User Tools

Site Tools


tools:graphicsmagick:color-replace

GraphicsMagick Color Replace

PMC Editing Wiki: Tools GraphicsMagick

2021-12-26

Command is -fill RGB_DESTINATION -opaque RGB_SOURCE.

This example replaces 255,255,255 (white) with 0,0,0 (black):

rem vte_grass
gm convert source.png -fill "rgb(0, 0, 0)" -opaque "rgb(255, 255, 255)" destination.bmp

However if your source image has transparent background and you do -opaque “rgb(0, 0, 0)” it will use the transparent background. GraphicsMagick thinks RGB 0,0,0 is transparent ;)

tools/graphicsmagick/color-replace.txt · Last modified: 2022-04-11 03:06 by snakeman