Color selector copy alpha

Is it possible to use the color selector tool to copy the transparency along with the color? (If not, I’d recommend supporting it via holding a modifier key.)

Pretty straightforward question, but I didn’t see any quick advise on the Krita Manual. It’s probably buried in there, somewhere, if it’s possible. Felt it belonged in beginner’s questions since it’s a fairly basic question.

No, opacity isn’t part of the color, and that’s intentional, I’m sorry.

Alright. Is there any way to read the opacity of a color that was drawn to the canvas? It would be… surprising to say the least, if this isn’t an existing feature, as it’s a very basic expectation that most image editors with layers (any of them, that I can think of) do support. Which is highly important honestly.

you could copy the color (with the eyedropper) and then try to adjust the brush opacity to get the same color with opacity.

That’s true. I would sooner export the layer to .png, and read the alpha in I could also use the clone stamp in Krita, I imagine, as another alternative.

Separating alpha from color is sensible as a general rule, and the eyedropper should respect it by default, as it currently does. But that alone isn’t enough to satisfy me on why we shouldn’t support copying alpha from a layer. The benefits of being able to do that are pretty apparent. I would consider it a useful feature; surely I’m not the only one to think so.

Could someone clarify whether Krita just currently doesn’t have a way to read alpha vs. Krita refuses to support a way to read alpha? In the latter case, I’d like a clear understanding of the design decisions, if possible.

I think it is not about refusing to support. There was never a request like this so the current colour picking method was created considering what the users expect. if more and more people start to ask for it I am sure there will be some interest in implementing it.

This is my personal opinion when painting I do not find the colour picking along with opacity any more useful than what we have now. Since I have not used any software which does this, my workflow is not accustomed to it.

Can you elaborate some use cases and scenarios where this will be helpful. Just to document it here.

1 Like

Certainly, and thanks. I came from, which allows this. I think it’s actually a commonly supported scenario.

The use case is that I may want to paint with transparency on a blank spot in a layer. Later, I might want to update the places that were painted, e.g. to extend the transparent colored region, but now I have to use a workaround to get the right opacity. I raised this question only after running directly into this scenario.

Workarounds include:

  • avoiding transparency on layers by always using transparency masks
  • carefully guessing what the opacity value was
  • Clone stamping and erasing, or duping to another layer, erasing & merging down
  • exporting the layer to .png to read the alpha value

Despite possible workarounds, it seems I and others could benefit from direct support to copy opacity of a pixel. My proposal was to add a modifier key that, when held, makes the eyedropper also copy the opacity of the color beneath it.

I think the color picker reads the amount of alpha where it makes a read. You can adjust it to the value it reads.

I can’t check right now to be certain though.

Yes it does. The RGB/A values are shown in the Tool Options docker when you use the main Colour Selector Tool.
The RGB values are copied into the colour selectors but the alpha value isn’t copied to the paint tools opacity slider.
This may be because different painting tools have different independently stored opacity values.

One possibilty would be to keep a record of the last-used painting tool and copy the picked alpha value to the opacity slider for that tool, if a modifier key is used (or an option has been set in the Tool Options docker).

(I realise that I have no true idea of the underlying structure and complexity of the code for that area and the difficulty of doing that.)

it’s not what you want, but that way you can discover the alpha without having to export to PNG.
See, I’m using the ‘color selector tool’
And I also set it to ‘sample current layer’ in the ‘tool option’ tab.
The screenshot didn’t capture the tool’s icon, so I boxed the area I was in.

Weird, I would expect alpha to be a value from 0 to 255, so I’m not sure what a value of 7k means. Thanks, though.

I believe it has to do with the properties of the image I’m working on (16bit). In an 8 bit file I got 0 ~ 255.
Well, I just wanted to present you with a way to get some values.

Funny that in 15 years of digital painting and drawing I never felt the need to pick the alpha of a color from the canvas.

1 Like

I agree and I don’t miss it.

But hypothetically speaking: in the case of a digital media where many things are possible, it could be implemented. Something that would automatically adjust the brush / bucket opacity from the dropper collection.

(I remember now: vector shapes have an alpha slider in the color palette. But of course, it’s another idea / concept)

Funny that your workflow isn’t the only one to exist :slight_smile:

Anyway, there are enough workarounds and ways to draw that skip the scenario of needing to have an opacity picker that, while I won’t back off saying it’s a useful feature, it’s plenty fine to ignore in light of more evidently important things.

if you do photo editing or compositing you will though.

I guess if I could read the alpha value with python I could make that happen.

P.S. - It seems the alpha channel is normalized to 1 always. Unless there is another way I am not aware I donno :frowning: I acctually thought this alpha was the color picker’s alpha read.

I’m sorry if this is inappropriate, I just made an account to chime in on this topic
Coming from Paint Tool Sai, I’m very very used to having the color picker as the click on my pen, and just picking fully transparent areas from the canvas in order to really really quickly turn my current brush into an eraser. I feel crippled now that I can’t swiftly swap like that.
In Paint Tool SAI though, I don’t think it stores alpha values as much as it just recognizes when it’s a fully transparent pixel and then turns “eraser mode” on on your brush. So it’s kind of different than applying alpha to the brush like that.

But it’s just another scenario where picking alpha would be helpful… I think? lol

Welcome to the forum.

Not disregarding your scenario or suggestion. Just giving you a workaround.
You can just Press E to turn your brush into an eraser. I believe it is faster than colour picking transparent area and turning a brush into an eraser. Since it takes time to search for transparent area and then hold ctrl and and click to pick the alpha, this also gives a headache when you are zoomed in an area of the painting where there is no fully transparent area. For me clearly pressing E solves this scenario.

1 Like