Sunday, October 10, 2010

Exclusion layer filter in Paint Shop Pro

What makes up the Exclusion layer filter in Paint Shop Pro? It works a bit differently than the Difference layer filter. The effects are shown below.

In the first screenshot, we see 3 color boxes in a layer called Layer1, set to 100% Normal.  Below that, I have selected 3 more boxes to copy to another layer. If I change Normal to Exclusion, there is no change in the image. This means the Exclusion layer looks the same.  It affects how you see the layers behind it, plus you see the remnants of the Exclusion layer.  Since there is nothing behind it, it shows up Normally on both Normal and Exclusion.  Let's see how it works in layers:

As you can see by my thumbnail overlay on Layer2, I added the boxes I selected from Layer1.  Then I switched the layer mode to Exclusion.  The darker colors are not excluding much... but the bottom brighter areas are shifting.  Look at these ranges: red 100% to white.  But there is a bit of cyan above the 50% mark.  This is the effect of Exclusion.

Here I have removed the color box from Layer1 so that it is transparent.  With nothing to exclude, the box returns to normal.

Instead of transparency in Layer1, what if it was a white box, as shown in the thumbnail?  Here is the effect of exclusion over a white box.  Not only are the colors reversed, but black and white are flipped! This is shown by the fact that the small color select circles have not moved.  This means black and white are both affected, which means this article at about.com is incorrect, as shown by this example.  Black is affected, if you exclude white with black (which the about.com author did not test).

With a black background: here is where the confusion lies. Notice that we flipped black and white above, but here against black we see no effect.  The effect here is "exclude black with black", which leaves us with black. It's a different pixel color calculation than the one above.

As a final test, I have taken a copy of the top box, flipped it, then mirror-imaged it.  What we see now is the bottom box flipped and mirrored, with a normal-looking 3 color box in Exclusion mode above that.  Black color is completely excluded out, another example that all colors are affected with one minor detail: once you hit 0,0,0, you can't go below that. Also, once you hit 255,255,255, you can't go above that.

Hopefully these examples have illustrated how the Exclude filter works in Paint Shop Pro. Unlike Difference, which reverses color and brightness, Exclude works differently, and 'removes' the color from the layer below it.  Also, white and black are absolutes with Exclude, whereas with Difference, they are simply 'flipped'.