Jump to content

Magic Wand "subtract" deselects all pixels even at very low tolerances


Recommended Posts

Can you give us some more info?

Exact steps & settings to reproduce what you are seeing?

Link to comment
Share on other sites

Tried it myself, I can confirm the bug.

 

  • For testing, make a black-white linear gradient.
  • Select the magic wand tool, set selection mode to replace, set the tolerance to 50%, then click on a completely black area. Part of the gradient will be selected. Finalize the selection.
  • Now, set the selection mode to subtract, set tolerance to 0%, then once again, click on the completely black area. Everything will be deselected.
  • Without finalizing the selection, increase tolerance above 50%. Additional areas outside of the original selection will be selected, but nothing in the original selection itself.

Edit: seems like the behavior of the subtract mode magic wand is the opposite of what it's supposed to do. Instead of dropping everything that is selected from the previous selection, it will keep everything that is selected but wasn't selected before.

 

Edit 2: Even weirder: Before using the magic wand for the second time, use the ellipse selection tool in subtract mode, then switch back to the magic wand. It will work as intended.

Edited by Rider01
  • Upvote 1
Link to comment
Share on other sites

"Edit 2: Even weirder: Before using the magic wand for the second time, use the ellipse selection tool in subtract mode, then switch back to the magic wand. It will work as intended."

 

But you have to Subtract with the Ellipse tool some of what was previously selected, if you try to subtract just wasn't selected previously it does not work as expected.
Create a diagonal Black to White linear gradient.

Use the rectangle select tool to select a rectangle in the center of the image.

with the ellipse (or any other) tool Subtract select outside the selection (blue) area.

With the Magic wand set at 15% tolerance subtract select in the middle of the rectangle
Areas outside the rectangle are selected!

Undo (Ctrl+Z)

With the ellipse (or other selection)tool subtract select as before but include a few pixels of the central selection rectangle

With the Magic wand set at 15% tolerance subtract select in the middle of the rectangle
only areas within the rectangle are de-selected!

Edited by gregors

/GregorS

Link to comment
Share on other sites

This is a bug in an optimization that I made.

The reason it doesn't happen if you do ellipse select stuff is that the optimization only applies if the two selection geometries being combined are both 1) completely within image boundaries, and 2) "pixelated" (rectilinear and only integer coordinates). Magic Wand always produces pixelated selection geometry, but an ellipse is definitely not.

The optimization is a huge one. Unfortunately it has a bug ...!

  • Upvote 1

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

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

forumSig_bmwE60.jpg

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.

×
×
  • Create New...