Pick Shortest Path tool, inconsistent selection
Open, Needs TriagePublic

Description

System Information
Suse Linux 42.2

Blender Version
Broken: 2.79b f4dc9f9d68b
Worked: (optional)

Short description of error
The Pick Shortest Path tool has a few oddities:

  • The first face is always selected and unaffected by the tool parameters - depending on the Nth and Skip settings, it should sometimes be unselected to preserve the sequence
  • But the last selected face *is* correctly influenced by the tool and depending on sequence can be both selected/unselected.
  • The default Offset value of 0 appears to be out by one unit and gives an irregular selection sequence at the start (in the examples given here, start = left side)
  • An Offset value of -1 gives consistent selection results

Exact steps for others to reproduce the error


Edit: reuploaded video (separate MP4 and MKV provided in case they don't play in all browsers).

See the attached video. But in case it's unavailable in future:

  1. create a plane and stretch it horizontally
  2. loop cut it 99 times (ctrl + r) - this gives 100 faces
  3. lmb on leftmost face, ctrl + rmb on rightmost face
  4. set Nth selection to 2, Skip to 4, Offset to 0
  5. observe that the selection from the left side is (where 0 = unselected, 1 = selected):

1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, etc

  1. If Offset is changed to -1 and we imagine that the first face is unselected, then the sequence becomes uniform/predictable:

0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, etc


Alternatively, these steps create a different sequence and might make it easier to see what's happening:

  1. create a plane and stretch it horizontally
  2. loop cut it 99 times (ctrl + r) - this gives 100 faces
  3. lmb on leftmost face, ctrl + rmb on rightmost face
  4. set Nth selection to 5, Skip to 3
  5. observe that the selection from the left side is (where 0 = unselected, 1 = selected):

1, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, etc

  1. If Offset is changed to -1 and we imagine that the first face is unselected, then the sequence is uniform:

0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, etc

Paul R (intracube) updated the task description. (Show Details)
Bastien Montagne (mont29) triaged this task as Incomplete priority.Jul 24 2018, 10:17 AM

Please follow our submission template and guidelines, also read these tips about bug reports, and make a complete, valid bug report, with required info, precise description of the issue, precise steps to reproduce it, small and simple .blend and/or other files to do so if needed, etc.
Videos and/or links to external sites etc. are not acceptable as bug report (they can be provided as additional information only).

I'm unsure what the issue is.

I've included the requested info; system info, Blender version, short description of error, exact steps both in video form and written as a step-by-step list.

Since the issue is with an interactive tool, a .blend can't be used to show the issue.

Also, whether it's intended or not, using bold text like that comes across as unnecessary and abrasive.

@Campbell Barton (campbellbarton) I also believe there is a problem with "Checker Select", in how it calculates the Offset.

Bastien Montagne (mont29) raised the priority of this task from Incomplete to Confirmed.Aug 13 2018, 3:59 PM

Indeed, something looks wrong in the checker logic, will investigate.

PS: What I find abrasive is having to lose time and copy-paste same canned answer countless times every week because people do not read our basic report rules. tracker is already an huge time and energy black hole, those rules are made to help us devs, so that we can quickly check and validate the bug, instead of spending time trying to carefully decipher the report and reproduce it ourselves.

Hi,

The offset now looks OK, but the first face is still permanently selected so we get sequences like this:


Also the Nth value seems to define the number of consecutive selected faces +1

So a value of 16 selects 15 faces. The tooltip also says it 'skips' though it's not clear what.

You select all elements but skip (not select) every Nth, (like 3, 6, 9...).
The Skip - number of consecutive elements to skip (not select) at once. (That breaks the "every Nth" logic.)

That's crazy.

Actually, there should be simply the "Number of Selected" and "Number of Unselected" elements.

Hi, any update on the first issue?

First face is still always selected, so this should be reopened.

You select all elements but skip (not select) every Nth, (like 3, 6, 9...).
The Skip - number of consecutive elements to skip (not select) at once. (That breaks the "every Nth" logic.)

That's crazy.

Yep, Skip set to any value other than 1 breaks the Nth element spacing.

Here's how the tool could logically work:

  • Skip should only have a range from 1 to the Nth element value -1, otherwise we'd just end up with nothing selected which is pointless.

It might be best to split this into a new task, since it wasn't part of the original report.

Yevgeny Makarov (jenkm) raised the priority of this task from Confirmed to Needs Triage.Aug 21 2018, 9:49 AM
Yevgeny Makarov (jenkm) reopened this task as Open.

The "first" element is not the first, it is the previous selection area,
before you perform Pick Shortest Path (or Shortest Path from menu),
so it should remain unchanged.

But then there's still the wrong offset.

And yes, the "Skip Nth" UX/UI very confusing and must be redesigned,
but it's not a bug, so it's not for this bug tracker.

The "first" element is not the first, it is the previous selection area,
before you perform Pick Shortest Path (or Shortest Path from menu),
so it should remain unchanged.

But the first face is included in the sequence pattern, otherwise we'd see an extra selected face at the start: 1110011001100 and that isn't what's happening.

So again, it's kind of inconsistent.

But then there's still the wrong offset.

The offset looks fixed in builds after the 14th Aug. What settings make it work incorrectly for you?

And yes, the "Skip Nth" UX/UI very confusing and must be redesigned,
but it's not a bug, so it's not for this bug tracker.

It's not just confusing, it doesn't do what the manual or interface text suggest.

Right now the tool is actually very close to the alternative logic you described further up: "there should be simply the "Number of Selected" and "Number of Unselected" elements." - if we pretend that the Nth element is 'number of selected' and Skip is 'number of unselected' then the only issue is that the Nth element value is out by one.

You have some selected area, in your case it's one element but can be any number (it is the previous selection area).
Then you perform Pick Shortest Path and it adds a new selection.
The previous selection should remain unchanged, i.e. first face in your case.

Paul R (intracube) added a comment.EditedAug 26 2018, 8:28 PM

You have some selected area, in your case it's one element but can be any number (it is the previous selection area).
Then you perform Pick Shortest Path and it adds a new selection.
The previous selection should remain unchanged, i.e. first face in your case.

Ah ok, so the tool is intentionally additive selection. That makes sense.

The logic all now seems OK if the controls are interpreted as 'number of consecutve selected elements + 1' and 'number of consecutive skipped elements'.

So aside from the Nth value being one unit too high, It's just the general naming/labeling that's out of step.

@Paul R (intracube) can you suggest exact changes, I'll check over them and commit if they make sense regarding the existing logic.

@Campbell Barton (campbellbarton) I can't think of a clearer description with the current logic so the existing labels/tooltips are probably best left as-is.

Anything else would need changes to the Nth and Skip, which would then break user scripts. The earlier commit might already do that...

@Paul R (intracube), I wouldn't worry about breaking user scripts for this particular operator, also with 2.8 we allow some breakage.