Mobile app version of vmapp.org
Login or Join
XinRu324

: Transform colors given 2x2 color pair in Photoshop I would like to transform colors in the attached image (and other hundreds) defined by the following rule: 1) the lightest blue became the

@XinRu324

Posted in: #AdobePhotoshop #ColorConversion

I would like to transform colors in the attached image (and other hundreds) defined by the following rule:


1) the lightest blue became the light green (exactly like as in the upper right color sample rectangle),
2) and the darkest blue became the dark green (exactly like as in the bottom right color sample)


I've tried to mod hue and lightness and can transform what satisfies 1) or 2) but not both at the same time.

Please note recreating the image with the 2 greens with gradient is not and option because I have many images with many details.



Thanks in advance

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @XinRu324

2 Comments

Sorted by latest first Latest Oldest Best

 

@Sims5801359

Not quite sure what the big problem is other than tediousness, which is annoying. But hey bill hourly right :)

Image -> Adjustment -> Replace Color. (I started with the bottom one)



Image -> Adjustment -> Replace Color on the top, but here you have to watch the setting. Once you see the black turn grey you went too far. I marked this with the red pencil.:



Back up so the rest stays black:



And we're done

10% popularity Vote Up Vote Down


 

@Shakeerah625

As the images are apparently not dithered to create the gradient, you have more than four colors (two greens and two blues) here. Note the histogram for your sample:



So as you are perhaps aware, you are looking at a potentially subtle recoloring process. There's blue in you "greens", green in your "blues", and red in there too somewhere. Results will be subjective and up to you to decide if they are good enough.

(Note: As @Ryan 's answer points out...if you don't mind losing all the gradients, you can achieve flat replacement of a color range with a single color using Image -> Adjustments -> Replace Color. You'll have to do some masking if you are doing multiple color range replacements that overlap each other, though.)

Were it me, I would ask the designer to provide assets of this type in source form...as opposed to needing to run this kind of filtering on the flattened and compressed output. It's hard to tell on such a small sample image, but I'd guess the colors have been web optimized because of the discrete gaps in the histogram; a continuous gradient would yield smoother distributions.

But if bugging the designer for source files isn't an option, you're up a bit of a creek as far as automated solutions go. Here's the pessimistic answer of "you can't":

How can I edit the colors in an already-placed, custom gradient in Photoshop?

Then again, you can bound regions, create masks from the gradient, use gradient maps to apply new gradients. Sky's the limit and anything is possible with a bit of cleverness (and the ability to place every pixel by hand if need be.)

You might get some ideas from this video as well:


But I'd find out if the designer actually has non-flattened forms of these dozens/hundreds of buttons/etc. and can give you files with more structure. If so, get those originals. If not, get them to change their practices and/or don't hire them again.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme