Bug 343285 - Inverting the selection changes the selection shape
Summary: Inverting the selection changes the selection shape
Status: RESOLVED DUPLICATE of bug 343365
Alias: None
Product: krita
Classification: Applications
Component: Tools (show other bugs)
Version: unspecified
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-25 16:38 UTC by kalia24
Modified: 2015-01-29 10:48 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description kalia24 2015-01-25 16:38:50 UTC
The version is 2.9 beta 2 (not in list).

Best to describe with pictures:
Original selection: http://i60.tinypic.com/2cpzy1g.jpg
Inverted selection: http://i58.tinypic.com/kos2w.jpg
Inversion seems to make a completely new selection instead of just inverting the existing one

Reproducible: Always

Steps to Reproduce:
1. Make a picture with some flaws around main shape and fuzzy edges.
2. Select the transparent part with the wand tool (Fuzziness = 20, rest = 0 for the above).
3. Invert selection (Ctrl+Shift+I).

Actual Results:  
Flaws and fuzzy edges get selected.

Expected Results:  
Flaws and fuzzy edges being outside the selection (since they belonged to the original selection).

Gave it a 'major' severity, since for me personally it's an important thing to be able to get shape in the picture, _exactly_ the  opposite to the one originally selected.
Comment 1 Halla Rempt 2015-01-27 09:07:20 UTC
Hm, I suspect that some parts were selected with very low values, and since the values get inverted, they now get more selected: that's actually to be expected. A selection is a gradient from 0 to 255, and if a pixel has a selection value of '1', the inverse is 254. Would that explain what you're seeing?
Comment 2 kalia24 2015-01-27 10:16:24 UTC
(In reply to Boudewijn Rempt from comment #1)
> Hm, I suspect that some parts were selected with very low values, and since
> the values get inverted, they now get more selected: that's actually to be
> expected. A selection is a gradient from 0 to 255, and if a pixel has a
> selection value of '1', the inverse is 254. Would that explain what you're
> seeing?

Yeah, though still it doesn't make things any better - it's certainly correct math-wise (and helpful when increasing/decreasing selection range) but quite useless graphic-wise (no way to get the literal opposite of selection). Or perhaps it is useful, but in some means that I don't use.
Lack of such trivial and basic function hurts.
Comment 3 Halla Rempt 2015-01-29 10:32:49 UTC
Is this with the same image you used for https://bugs.kde.org/show_bug.cgi?id=343365 ?
Comment 4 kalia24 2015-01-29 10:36:53 UTC
(In reply to Boudewijn Rempt from comment #3)
> Is this with the same image you used for
> https://bugs.kde.org/show_bug.cgi?id=343365 ?

Yup.
Comment 5 Halla Rempt 2015-01-29 10:44:44 UTC
And was the original selection you inverted created with the magic wand tool?
Comment 6 kalia24 2015-01-29 10:45:43 UTC
(In reply to Boudewijn Rempt from comment #5)
> And was the original selection you inverted created with the magic wand tool?

Yup :)
Comment 7 Halla Rempt 2015-01-29 10:48:00 UTC
Okay -- then I'm pretty sure it's the same bug, actually! Thanks for your patience -- I need Dmitry to look into the other bug, since he actually caused the regression!

*** This bug has been marked as a duplicate of bug 343365 ***