Hi everyone,
I'm looking for a way to colorize PNG image, regardless the PNG's content.
For example, if I take these two differents PNG:
and I want to give them a green tint, the output should be:
(photoshop approximation)
Any help would be appreciated.
IM version 6.7.7-10 2014-03-08 Q16
Trying to colorize png
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Trying to colorize png
This isn't exactly the same as your desired output (Windows BAT syntax):
Code: Select all
convert sr3BsQF.png -modulate 100,0,100 +level-colors rgb(0,50%%,0),lime a.png
convert R8Y94q4.png -modulate 100,0,100 +level-colors rgb(0,50%%,0),lime b.png
snibgo's IM pages: im.snibgo.com
Re: Trying to colorize png
Thank you snibgo !
It does almost what I need
It works perfectly well for markers like the first one, but the second marker's colors are flatten..
This one was converted with a simple hex color
convert marker2.png -modulate 100,0,100 +level-colors '#ff8400' result.png
It does almost what I need
It works perfectly well for markers like the first one, but the second marker's colors are flatten..
This one was converted with a simple hex color
convert marker2.png -modulate 100,0,100 +level-colors '#ff8400' result.png
-
- Posts: 23
- Joined: 2011-04-10T14:08:11-07:00
- Authentication code: 8675308
Re: Trying to colorize png
From the section : http://www.imagemagick.org/Usage/color_ ... dulate_hue
I edited the lines to fit your image that was uploaded.
convert YPuLOBp.png -modulate 100,100,0 YPuLOBp_mod_hue_0.png
convert YPuLOBp.png -modulate 100,100,33.3 YPuLOBp_mod_hue_33.png
convert YPuLOBp.png -modulate 100,100,66.6 YPuLOBp_mod_hue_66.png
convert YPuLOBp.png -modulate 100,100,100 YPuLOBp_mod_hue_100.png
convert YPuLOBp.png -modulate 100,100,133.3 YPuLOBp_mod_hue_133.png
convert YPuLOBp.png -modulate 100,100,166.6 YPuLOBp_mod_hue_166.png
convert YPuLOBp.png -modulate 100,100,200 YPuLOBp_mod_hue_200.png
I'm new to some of the tricks but this one I noticed it when I was making a trip out background for a chroma screen, chances are your looking more for applying a color filter to have them all in the same range.
Only other goodies I found we're at Freds page
http://www.fmwconcepts.com/imagemagick/ ... /index.php Convert your image to grey scale then back to 3 color tints
or http://www.fmwconcepts.com/imagemagick/ ... /index.php which gives you a hue wheel to work with.
Hope this helps or gives ideas to others to point you in the right direction
I edited the lines to fit your image that was uploaded.
convert YPuLOBp.png -modulate 100,100,0 YPuLOBp_mod_hue_0.png
convert YPuLOBp.png -modulate 100,100,33.3 YPuLOBp_mod_hue_33.png
convert YPuLOBp.png -modulate 100,100,66.6 YPuLOBp_mod_hue_66.png
convert YPuLOBp.png -modulate 100,100,100 YPuLOBp_mod_hue_100.png
convert YPuLOBp.png -modulate 100,100,133.3 YPuLOBp_mod_hue_133.png
convert YPuLOBp.png -modulate 100,100,166.6 YPuLOBp_mod_hue_166.png
convert YPuLOBp.png -modulate 100,100,200 YPuLOBp_mod_hue_200.png
I'm new to some of the tricks but this one I noticed it when I was making a trip out background for a chroma screen, chances are your looking more for applying a color filter to have them all in the same range.
Only other goodies I found we're at Freds page
http://www.fmwconcepts.com/imagemagick/ ... /index.php Convert your image to grey scale then back to 3 color tints
or http://www.fmwconcepts.com/imagemagick/ ... /index.php which gives you a hue wheel to work with.
Hope this helps or gives ideas to others to point you in the right direction