Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Replacing colors on index color image
#1
Hi! I would like to create some 8-bit pixel art, and I'm considering using GIMP for it.

The image I'm creating uses index color with a 256-color palette. My question is the following: I would like to recolor all the pixels in a selected part of my image from one color to another, without changing the palette nor the rest of the image.

I've learnt how to use the Color Selection tool (Shift-O) to pick a specific color, and to replace it with the foreground color (Command-,). However, by doing this, the color is replaced over the entire image. I tried to select a rectangular area before ®, but then, right after I pick the color to be changed, my selection is gone and the replacement takes effect over the whole image.
Is there a way to restrict the swapping to just part of my image?

I'm using GIMP 2.10.38 on OSX 10.13.6 .

Thanks in advance!
Reply
#2
The selection should remain and the color be replaced only on the selected part. However, I don't know what Command - does. The tools you want to use after the selection is the bucket-fill(*).

Of course if your new color isn't in the color map, you won't get the color you want, see https://www.gimp-forum.net/Thread-What-a...-all-wrong

(*) While checking this, I found that the brush seems to ignore the selection in some cases, and this could be a bug, so if you are using the brush, use the bucket.
Reply
#3
(12-23-2024, 09:38 AM)Ofnuts Wrote: The selection should remain and the color be replaced only on the selected part. However, I don't know what Command - does. The tools you want to use after the selection is the bucket-fill(*).

Of course if your new color isn't in the color map, you won't get the color you want, see https://www.gimp-forum.net/Thread-What-a...-all-wrong

(*) While checking this, I found that the brush seems to ignore the selection in some cases, and this could be a bug, so if you are using the brush, use the bucket.

Thanks for your answer! You pointed me to the right direction. I just noticed that I didn't select "Intersect with current selection" in the instrument panel before using the bucket: that's why Gimp was ignoring my selection. After correcting for this, it now works fine.

Thanks again!
Reply


Forum Jump: