Jump to content

What EXACTLY does the "Xor" blending mode do?

Recommended Posts

The official documentation on this mode is frustratingly vague:

Thing is, I do personally use it to make art. I think if I knew what exactly it did, I could more easily create images that have eye-pleasing results when blended together using xor.


Any help or information you can give is appreciated!


None of these links are family-friendly, but they should still be safe for work.

Link to comment
Share on other sites


XOR basically means "x or y, but not both." When the two pixel values being compared are the same, you get 000000 (black), and when they are opposites, you get FFFFFF (white). Things in between vary based on how different the pixel values are from each other.

@Anonymous If you don't have anything useful to say, don't post.


what I do all summer Emote Cursor Pack 'noob gallery



Link to comment
Share on other sites

As pdnnob told it is and exclusive or operation on bitlevel.


So for each bit N in the 24 bit RGB triple

    compositeBitN = layer1BitN ^ layer2BitN  (0^0=0, 1^0=1, 0^1=1, 1^1=0)

Alpha handling is more complex. So I would use opaque layers only.

midoras signature.gif

Link to comment
Share on other sites



Alpha is handled the same regardless of blending mode. Only the treatment of the color channels is affected by your choice of blending mode.

The Paint.NET Blog: https://blog.getpaint.net/

Donations are always appreciated! https://www.getpaint.net/donate.html


Link to comment
Share on other sites

Join the conversation


Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.


×   Your previous content has been restored.   Clear editor



  • Create New...