0

I have a set of .png images (which are controls like buttons, sliders, checkbox etc for a GUI) and I'd like to convert a specific color to another for each files using an automatic solution.

For example, let's say that my input are theses three files

button_small.png
button_medium.png
button_large.png

which are yellow buttons with a black stroke.

I'd like my output to be the same (name, paths, sizes) but with the yellow color (or hex value) replaced by orange color (or an other hex value).

Is there any solution, like a script or photoshop tool ?

Thanks.

6
  • It depends a bit on how your buttons actually look like. Are the yellow pixels really one single hex color or is there a range of values caused by anti-aliasing? – Wolff Mar 2 at 19:00
  • Hi. Welcome to GDSE. Hard to say what might or not be possible without access to the PNG files. Can you share them? – Billy Kerr Mar 2 at 19:01
  • @Wolff: somes are, other not. but let's say for a single hex color – PLB Mar 3 at 7:26
  • @BillyKerr: yes sure, it's controls files from touchgfx designer: easyupload.io/kagd3z – PLB Mar 3 at 7:26
  • There's some anti-aliasing and shading on the buttons, so perhaps a Hue/Saturation adjustment would work for you. You could record it as an Action and apply to a whole folder of PNGs using File > Automate > Batch. – Billy Kerr Mar 3 at 10:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.