Post Reply 

Bucket fill effect on alpha channel

Dec 17, 2010, 01:16
Post: #1
Bucket fill effect on alpha channel
Hi,

I'm new to gimp forums and relatively new to gimp.

I have a PNG logo that has anti-aliased letters on a transparent background. In other words, all pixels are white (for example) and either 0% tranparent (in the letters) or semi-transparent (in the anti-aliasing). The rest of the image is transparent.

What I'm trying to do is take change the color of the logo. Bucket fill in normal mode changes the alpha value of the semi-transparent pixels to 0% transparent when applying the color--so I loose the anti-aliasing. I did manage to get what I want with bucket fill mode Darken only, but this only works for certain colors on certain other colors (I can change white to any other color, but not vice versa).

Is there a straightforward way to fill a color while keeping the alpha channel intact? I tried all the modes, and also modifying the Fill transparent areas, but don't really understand them to figure out if one does this in the general case.
Find all posts by this user
Quote this message in a reply
Dec 17, 2010, 19:42
Post: #2
RE: Bucket fill effect on alpha channel
Hi Ofnuts,

Thanks for the two suggestions, but they don't quite work. I had played with the Alpha to selection before, but I never got it to work quite right. The way it does the selection, it leaves out some of the anti-aliasing (some of the semi-transparent pixels).

If I do it twice (using Add to selection the second time) it looks like it grabs exactly what I want--but why twice? What that tells me is that the selection it is doing has some sort of threshold but not one I can adjust--thus I can never know exactly what it's doing.

Your second method doesn't work right, even if I add to selection in the second step. Something in the inverting and erasing adds extra pixels to my outlines in a way I don't understand (the pixels exist in the part I deleted--how can that be?). So actually, your first method works the best if I do Add to selection.

Actually, the Darken Only and Lighten Only modes on the bucket fill seem to work the best, and that's just a single click. But it still feels like a workaround that may not work in all cases (for example if my logo were multicolored to begin with). I think the problem is that the other modes don't handle the alpha channel correctly (or clearly). It seems like there should be a mode to Preserve Alpha.
Find all posts by this user
Quote this message in a reply
Feb 2, 2011, 02:54
Post: #3
RE: Bucket fill effect on alpha channel
Windows->Dockable Dialogs->Layers
Check 'Lock alpha channel' box for the layer and use normal bucket fill
Find all posts by this user
Quote this message in a reply
Jun 12, 2013, 04:22
Post: #4
RE: Bucket fill effect on alpha channel
(Feb 2, 2011 02:54)marina Wrote:  Windows->Dockable Dialogs->Layers
Check 'Lock alpha channel' box for the layer and use normal bucket fill
Assuming this is the box (chain link icon) just to the right of the layer visibility (eye icon) box, it seems to have no effect on bucket fill in GIMP 2.8.2 for Windows.

However, I found a solution: select area you want to change colour, then Colors menu -> Colorify. Did exactly what I wanted with an image made of just white pixels and alpha channel as seemingly described in the OP. HTHS.
Find all posts by this user
Quote this message in a reply
Jun 16, 2013, 22:38 (This post was last modified: Jun 17, 2013 03:40 by fryerlawrence.)
Post: #5
RE: Bucket fill effect on alpha channel
        [attachment=2131][attachment=2132][attachment=2129][attachment=2130]Uhhhh ummmm need help....lol

I have tried everything listed and still cannot get the paint bucket to work. I am trying to edit plane liveries for a flight game that I am playing.

I just today started learning to get into the Alpha channels. I think I may have toggled something that I cannot find or see if there is a switch to be flipped...lol

I am working with "Channels" and "Layers tabs in the "Channels" tool window. When I think I have everything back to normal. I am choosing the Paint Bucket > clicking on the only layer in the "Channels" tab > then I go to use the Paint Bucket. It acts like it does something but the only layer that was highlighted in blue (to notate selection) my selected layer that is highlighted disappears and nothing happens. I do click CTRL + Z just to make sure I am not doing something in the background that I cannot see.



Thanks for the help in advance,
-fryer

[Image: flying-pig-rocket-to-the-moon-or-bust_2_zps119f0e3a.jpg] “With sufficient thrust, pigs fly just fine.” -Unknown Author
Find all posts by this user
Quote this message in a reply
Jun 17, 2013, 03:22 (This post was last modified: Jun 17, 2013 03:53 by fryerlawrence.)
Post: #6
RE: Bucket fill effect on alpha channel
Sorry about that... I think I got the screenshots on the right attachment...lol

Am gonna check based on what you said in the meantime.

Follow up question about brushes... This image that I am working with has thousands of pixels... I am assuming that is the way that Microsoft Studios made it in the first place.

Basically what I am trying to do is re-color the plane and also add some decals. I could of used your advice when I was working on my other project. I made a C-46 Curtiss Commando Flyin' Whale (an Orca... aka Shamu...lol)

Thanks,
-fryer


Attached File(s) Thumbnail(s)
   

[Image: flying-pig-rocket-to-the-moon-or-bust_2_zps119f0e3a.jpg] “With sufficient thrust, pigs fly just fine.” -Unknown Author
Find all posts by this user
Quote this message in a reply
Jun 17, 2013, 03:22
Post: #7
RE: Bucket fill effect on alpha channel
Sorry about that... I think I got the screenshots on the right attachment...lol

Am gonna check based on what you said in the meantime.

Thanks,
-fryer

[Image: flying-pig-rocket-to-the-moon-or-bust_2_zps119f0e3a.jpg] “With sufficient thrust, pigs fly just fine.” -Unknown Author
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Scaling layer does not scale alpha! WallyZ 1 167 Apr 3, 2018 06:22
Last Post: blighty
  Bucket Fill Not Working Suddenly stephengb 1 151 Mar 4, 2018 06:02
Last Post: paynekj
  Lighting Effect without darkness cayviel 1 121 Feb 16, 2018 05:13
Last Post: ythgilb
  Best way to bucket fill ink drawing? southofmotown 1 183 Feb 11, 2018 20:59
Last Post: paynekj
  How to push changes to a channel to multiple layers using that channel as a mask? CunningAllusionment 1 170 Jan 2, 2018 09:18
Last Post: paynekj

Forum Jump:


GIMP ForumPortalArchiveContactTermsRSS