Jump to content

Using channel mixer for masks

Recommended Posts

There is a repeating wish that people would like to use the full scale of editing tools on masks, and handle them as grayscale layers. They are usually told that masks only have the alpha channel, and they are mistaken to think that values of alpha are considered shades of gray.

I think this is not the full story. One can use a regular pixel layer as mask, and the alpha channel (transparency) of the pixel layer will be used for masking, while ignoring the RGB channels of it. Furthermore it is possible to put a live Channel mixer adjustment on top of a pixel layer which makes it transparent based on it's luminosity. Combine these two tricks, you get a mask, where you can do every aspect of grayscale editing.

Here are the steps:

You have pixel layer A you would like to mask, and pixel layer M you would like to use as mask. You nest a Channel Mixer adjustment inside M, choose LAB channels, Alpha channel, make contribution of input Alpha 0, and contribution of input Lightness 100% into Alpha. Layer M should be above layer A. Right-click layer M, and choose Mask to Below. Bam, you have a mask pixel layer to do any edits and it's luminosity is used for masking. (beware of a GUI limitation that nested children of masks are not shown on the layers panel)

What do you think?




Link to comment
Share on other sites

  • 3 weeks later...

Interesting looking technique that should prove useful. Thanks.

Perhaps, as it already works, it should have been in Tutorials rather than Feature Requests, so more of us would see it or be able to find it easily?


-- Walt

Desktop:  Windows 11 Home, version 22H2 (22621.1413) 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 
Laptop:  Windows 10 Home, version 21H2 (19044.2728) 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
        Affinity Photo 1.10.6 (.1665) and 2.0.4  and beta/ Affinity Designer 1.10.6 (.1665)  and 2.0.4  and beta / Affinity Publisher 1.10.6 (.1665)  and 2.0.4  and beta
iPad Pro M1, 12.9", iPadOS 16.3.1, Apple Pencil 2, Magic Keyboard

      Affinity Photo 1.10.7 and 2.0.4 and beta/ Affinity Designer 1.10.7 and 2.0.4 and beta/ Affinity Publisher 2.0.4 and beta

Link to comment
Share on other sites

  • 1 year later...

This thread is over my head.  I found it looking for luminosity mask info.  A question- what would this technique be used for exactly?  I'm not clear on the meaning of gray scale editing.  Is that editing black and white photos or, something to do with "white reveals, black conceals" ?

Thanks for taking the time post on this technique.

EDIT: Went and watched/worked with the Channels videos and I believe I'm on the same page now.  The videos are found Here - Affinity Photo - Channels for Alpha Masking  and Here - Affinity Photo - Channels: Greyscale Blending.  If there are other learning opportunities you're aware of, please post.


Edited by Clifford Rourke
Add info on researching this topic.
Link to comment
Share on other sites

  • 3 months later...


I come back on this post, the first time I had not understood the subtlety...

Concerning the layer M intended to realize the future mask, it is more precise to do it according to the layer L * without colorimetric interference

therefore  go  (Channels, clear A clear BOpponoent). 

After Duplicate It is possible to invert with ctrl I,  subtract, in fact obtain real masks of luminance in 16 bit

Remenber :

L * = white (L +) vs "black" (L = 0)
a * = red (a +) vs green (a-)
b * = yellow (b +) vs blue (b-)


It is possible to create a modulation of transparency (alpha) according to the opposite colors (red, green, yellow, blue ...) mixte with evenutally the luminance..

very powerful 

Link to comment
Share on other sites

  • 2 weeks later...


For the "a and m" version, so far, I get no joy.  Got it all set up, added a curves adjustment, turn the mask on and off and = no effect.  I put the curves layer above, below, nested, every place it could go and find no change switching the mask layer on and off.

Perhaps one of you could post a 'next step' for this.  What did you do next with your creation?

I didn't try Max's version as he has me completely lost.  I am not familiar with Lab color controls so there is too much "short hand" in the post for me to understand- my bad.  Again, please post the 'next step' or an example of how to use this mask making technique.  A question- does M simply get replaced with L?

Best regards,

Clifford Rourke

chnk mixr mask uncheck.png

Edited by Clifford Rourke
Clarify comment and ask a question.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

Please note there is currently a delay in replying to some post. See pinned thread in the Questions forum. These are the Terms of Use you will be asked to agree to if you join the forum. | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.