Take the 2-minute tour ×
Graphic Design Stack Exchange is a question and answer site for Graphic Design professionals, students, and enthusiasts. It's 100% free, no registration required.

I'm pretty new to Photoshop. I would like to change the color of this object on my .png image: original

But anyway I try, it becomes this fuzzy with the new color:

modified

How can I change it's color to stay in it's original shape?

share|improve this question
    
FYI: the reason your result looks the way it does is that, in the original image, the edges have a less-that 100% black pixel. The edge pixels are either partially transparent or just some value of grey. You appear to be using the flood-fill paint bucket which colors these grey areas 100% black (or at least something darker than before). Bakabaka's two "non-destructive" options which involve masks or overlays will give you a good result. –  horatio Jan 23 at 19:42

2 Answers 2

up vote 15 down vote accepted

There's multiple ways. The easiest would be to add a 'colour overlay' layer style.

  • Double-click the empty area in the Layers palette, on the right of the layer's title. This will open the 'Layer Styles' dialogue box.
  • Click the words 'Color Overlay' on the left -- just clicking the checkmark isn't enough.
  • Click the colored rectangle in the mid-top of the dialogue box to pop up the colour picker and choose your colour.
  • Click 'OK' to leave the colour picker and confirm, and 'OK' again to leave the layer style dialogue and confirm.

This is a non-destructive effect (you can revert or alter it as needed), but only if you save it as a *.psd file. If you save as *.png, it will just be the new colour.

A more direct way might be to destructively alter the pixels' colour:

  • In the layer palette, seek out the word 'lock', and click on the checkerboard icon next to it. This will lock the layer's opacity: you can edit the layer as you like, but pixels will retain their current opacity value.
  • Paint in your colour in any way you like.
  • Unlock the transparency again to prevent stumping yourself later.

Since it's the loss of opacity anti-aliasing that creates your unwanted effect, locking the opacity will prevent this from happening.

EDIT: As proposed by Larme in their comment, here is another non-destructive method:

  • create a second layer above your layer and fill it with your colour. This can be a 'solid color' layer or just a pixel layer filled with the desired colour.
  • right-click in the empty part of this layer in the layers palette, and choose 'Create Clipping Mask' OR hold Alt and click on the border between the two layers in the palette (you'll see a square and arrow cursor).

This way, the bottom layer's transparency act as a mask for the top layer.

share|improve this answer
5  
Another good way is to fill a new layer above the on with one color, and convert it as a Clipping Mask (after a right click on the layer). You can now only modify the clipped layer with various colours if needed to. –  Larme Jan 23 at 13:21

Find the 'Lock Transparent Pixels' button

Then fill everything with the colour you want.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.