Jump to content

Transparency in blend modes


Recommended Posts

I want to create a mask layer that will allow me to modify the image really fast, and I use alpha a lot.

Normally this is done using the "multiply" blend mode, but in pdn the transparency seems to be ignored...

 

A multiply is (colors between 0 and 1):

dest.R = layerA.R * layerB.R

dest.G = layerA.G * layerB.G

dest.B = layerA.B * layerB.B

dest.A = layerA.A * layerB.A

 

meaning that if you have a fully transparent pixel in the mask or the other layer then the resulting pixel will also be fully transparent. However in pdn that is not the case... How does Paint.net handle this, and how can I achieve what I want ?

 

Thanks !

Edited by Synxis
Link to comment
Share on other sites

Sorry, I'm not a techy girl, so I don't think I understand what you want. But, we do have a plugin called alpha mask : http://forums.getpaint.net/index.php?/topic/1854-alpha-mask-import-plugin-20/.
Now, I don't know photoshop, but I don't think this plugin is quite like photoshop's masks, if that's what you are thinking of. This alpha mask mostly functions by having black shapes, copying, and running the plugin. To understand it's function better, look for tutorials that use it.

If you like working with blend modes, then something else you might be interested in, is in paint.net 4.0 you can use "Copy Merged" to turn checked layers into one layer. This works well for stacked blend modes.

To do this, first make a selection or "select all (ctrl + a)" on your top layer that's checked, then go to Menu Bar > Edit Tab > Copy Merged. Now, add a new layer and paste. Again, I'm not sure if this helps with what you are asking for, but maybe you will find it handy in another way.

 

There is also this explanation on paint.net's blend modes, maybe it will help you : http://www.getpaint.net/doc/latest/BlendModes.html

 

I hope someone who is more techy than me will be able to help you better, but either way, good luck!

Edited by Cc4FuzzyHuggles
Link to comment
Share on other sites

Thanks for the hint, but I already ruled out that plugin because I have a lot of layers to selectively show/hide, then mask, then copy the flattened image to another one (to generate an animated sprite), and repeat. Doing a copy paste every time would quite defeat the idea of having a mask... And I don't have Paint.NET 4 for the moment.

 

To explain more precisely what I want : imagine a 1x1 image with 2 layers, layerA on top of layerB.

The pixel of layerA is 100% opaque red (in RGBA: [255, 0, 0, 255])

The pixel of layerB is 50% transparent white (in RGBA: [255, 255, 255, 128])

If you set layerA to be on multiply, the resulting pixel currently will be in RGBA: [255, 0, 0, 255]. However, that is not what I want, and it is also not correct. The result I expect is [255, 0, 0, 128], since:

 - for R, 255 * 255 / 255 (the division to put the result between 0 and 255) is 255

 - for G, 255 * 0 / 255 is 0

 - for B, 255 * 0 / 255 is 0

 - for alpha, the same formula should apply, so 255 * 128 / 255 is 128 (the result I want).

 

I hope I explained it clearly.

 

If it is possible to have additionnal blend modes as plugins, then I can create a plugin for that.

Link to comment
Share on other sites

Hello Synxis (welcome to the forum!),

I believe the layer blend modes treat alpha differently to the other channels.
Unfortunately Plugins can only access the selected layer - (you can get araound this by using the clipboard image).
Whether that would be practical for your purpose I doubt though.

Sometime ago the question of having an 'alpha-mask' layer blend mode was raised and Rick said it would involve changing the Pdn file type. So I can't see an easy soloution I'm afraid. (Sorry - I can't find the link to that discussion).

 

Red ochre Plugin pack.............. Diabolical Drawings ................Real Paintings

 

PdnForumSig2.jpg

Link to comment
Share on other sites

Is there anything stopping you from trying paint.net 4.0? (again, not sure if it would help you, since blend modes function the same with it, but maybe it's worth a look as it might be useful in other ways?). You can have both 4.0 and 3.5.11 installed at the same time.  Here is a thread which explains it a little. http://forums.getpaint.net/index.php?/topic/28279-how-to-open-3511-after-installing-40/

(I use both, because some plugins don't work in 4.0)

 

And, if you want more blend modes, have you tried this plugin? PlendModes Plus : http://forums.getpaint.net/index.php?/topic/16607-blendmodes-plus-v235-32410/

Edited by Cc4FuzzyHuggles
Link to comment
Share on other sites

 

Unfortunately Plugins can only access the selected layer - (you can get araound this by using the clipboard image).

Oh, that's too bad... So no workaround for this. I guess I will try the plugin linked by Cc4FuzzyHuggles.

 

 

Is there anything stopping you from trying paint.net 4.0?

Not really, but if there are no big new feature (or this blend mode) I won't switch as long as it is a beta. But if the 4.0 is able to do what I want faster, then I will get it.

 

 

Are you sure about that there is an application in which the blendmode affects the alpha channel?

I tried photoshop, but it handles multiply the same than PDN. However, a lot of games have the multiply operation I discribed as an important way of blending images.

Usually, the layer opacity would be what is used as the factor, and the alpha channel is treated like r, g and b. It allows greater control over the image.

 

Having such a blend mode implemented directly in PDN would be really nice, for example with a checkbox 'Treat alpha as a color' next to the list of blend modes.

 

Thanks for the help anyway !

Link to comment
Share on other sites

Link to comment
Share on other sites

Sometime ago the question of having an 'alpha-mask' layer blend mode was raised and Rick said it would involve changing the Pdn file type. So I can't see an easy soloution I'm afraid. (Sorry - I can't find the link to that discussion).

 

http://forums.getpaint.net/index.php?/topic/24961-the-new-layer-styles-request-topic-for-paintnet-40/?p=376960

  • Upvote 1
Link to comment
Share on other sites

I knew I'd asked that question.  Surprised me how long ago that post was :(

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.

Guest
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.

 Share

×
×
  • Create New...