← All ideas
  • Published 21 Jul 2020

Grease Pencil. Stroke > Join uses selected points to figure out which ends to join together

Right now Stroke > Join uses the direction of the strokes to determine which ends should join together. Often this isn't what we want.

image

A better Stroke > Join would use the selected points to figure out which ends of the strokes to join together. The ends closest to the selected points would be used.

image

joinpoints.png

100%

Development Status: Done

tomasz.brain
21 Jul 2020

8 Comments

simonrepp

I too struggle with this regularly. In general I feel that various GP operations for accurately editing and cleaning up strokes are currently quirky and unpolished (they behave very much unlike their equals in mesh objects), although I suspect there is not really any strong reason for that: The problems they solve seem reasonably simple in terms of space and topology and I can only speculate there was just missing incentive and drive to polish them so far.

On the positive side, today I ran into this again for the 100th time or so, and finally got annoyed enough to decide to look into it myself now haha. No promises yet, but so far this looks solvable both in terms of the UX questions and implementation steps involved.

From my initial sourcecode review I actually have a mild suspicion that asides the idea to make this operator interact with the point selection, there is actually a bug in the implementation right now whose resolution coincidentally would already help with the usecase you're demonstrating in your images - regardless of which points are selected.

In code the documentation reads:

/* Join two strokes using the shortest distance (reorder stroke if necessary ) */
void BKE_gpencil_stroke_join(bGPDstroke *gps_a, ...

Now compare that with the images you posted - clearly either the functionality claim in the documentation for the operator is wrong, or the implementation is. I'll report back when I know more. Meanwhile I invite everyone to give this some votes, compared with most of the feature proposals on rightclickselect this is a low hanging fruit, it just needs some community buzz. :)

1
simonrepp

Turns out the reason the operator behavior (in 2.91) does not match the behavior stated in the inline documentation is because the operator was meanwhile rewritten during 2.92 alpha development: developer.blender.org/D9359 ¡Gracias Antonio! :)

Upcoming 2.92 release notes do not currently state anything on the specific feature requested here (see wiki.blender.org/wiki/Reference/Release_Notes/2.92/Grease_Pencil ) but seeing below that Antonio likes the idea, I'll just stand back and see what happens now before putting more time into something that maybe already is on its way. :)

matias.mendiola

Implemented in version 2.92 developer.blender.org/D9359

matt6

If I'm not wrong, this proposal wasn't implemented. The proposal is to use the selected points (if any are selected) and join the strokes at those two points or the closest stroke ends if the selected points aren't at the end of their strokes. The difference is that with this proposal the user can pick which two ends get joined instead of blender picking.

Multiple times, I have selected two points to join together but then blender decides to join the strokes at the other ends because they're closer together. When this happens, I then have to connect the two points I wanted with F and then get rid of the connection between the other two that blender decided to connect. It would be much nicer if I could just tell blender which points to connect.

cptdjb

What's your work around at the moment? I cannot find flip stroke direction at all

simonrepp

* @cptdjb * The operator is called " Switch direction" (access through the F3 search shortcut or in the Strokes menu). You can see the operator shown in the open menu in two of the screenshots above too.

agungbasuda973

this supposed to be how it should, i dunno d intention of making it like what we have right now

antonioya

I like the idea!