{"action":"created","issue":{"url":"https://api.github.com/repos/inkstitch/inkstitch/issues/214","repository_url":"https://api.github.com/repos/inkstitch/inkstitch","labels_url":"https://api.github.com/repos/inkstitch/inkstitch/issues/214/labels{/name}","comments_url":"https://api.github.com/repos/inkstitch/inkstitch/issues/214/comments","events_url":"https://api.github.com/repos/inkstitch/inkstitch/issues/214/events","html_url":"https://github.com/inkstitch/inkstitch/issues/214","id":336039259,"node_id":"MDU6SXNzdWUzMzYwMzkyNTk=","number":214,"title":"Auto-routed Satin Column","user":{"login":"lexelby","id":4446653,"node_id":"MDQ6VXNlcjQ0NDY2NTM=","avatar_url":"https://avatars1.githubusercontent.com/u/4446653?v=4","gravatar_id":"","url":"https://api.github.com/users/lexelby","html_url":"https://github.com/lexelby","followers_url":"https://api.github.com/users/lexelby/followers","following_url":"https://api.github.com/users/lexelby/following{/other_user}","gists_url":"https://api.github.com/users/lexelby/gists{/gist_id}","starred_url":"https://api.github.com/users/lexelby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexelby/subscriptions","organizations_url":"https://api.github.com/users/lexelby/orgs","repos_url":"https://api.github.com/users/lexelby/repos","events_url":"https://api.github.com/users/lexelby/events{/privacy}","received_events_url":"https://api.github.com/users/lexelby/received_events","type":"User","site_admin":false},"labels":[{"id":844786428,"node_id":"MDU6TGFiZWw4NDQ3ODY0Mjg=","url":"https://api.github.com/repos/inkstitch/inkstitch/labels/feature%20request","name":"feature request","color":"c2e0c6","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":15,"created_at":"2018-06-27T00:45:25Z","updated_at":"2018-07-24T00:56:38Z","closed_at":null,"author_association":"MEMBER","body":"It would be cool if Ink/Stitch could automatically determine a stitch order for a group of satin column objects.  It would break satins if necessary and add running stitch between sections, always ensuring that the running stitch is hidden by later satin stitching whenever possible.  Start/end markers should also be possible as in #20.\r\n\r\nMuch like with AutoFill, the algorithm is going to be tricky.  Also as with AutoFill, I'm not sure how to have the user specify this in the SVG.\r\n\r\nHow would the user tell Ink/Stitch that a group of satins should be treated as a single unit for purposes of automatic routing?  I can think of two options, both with pros and cons:\r\n\r\n1. Group the satins together (Object -> Group)\r\n  * **Pros**:\r\n    * easy to do in Inkscape UI\r\n    * easy for Ink/Stitch to parse\r\n  * **Cons**:\r\n    * no visual indication of which satins are included in the group\r\n2. Add a Command (symbol) for \"auto-satin\" and draw a connector line to each satin that should be part of the group.\r\n  * **Pros**:\r\n    * visually obvious that the satins are grouped together\r\n    * (mostly) easy for Ink/Stitch to parse\r\n  * **Cons**:\r\n    * **nearly impossible** to do in Inkscape UI\r\n      * The flow-chart Connector tool does not allow for drawing a connector line to an unclosed path like a Satin column.\r\n      * Possible workaround: select the satins and run an extension, \"Group Auto-Satin\", that creates the auto-satin symbol and sets up the connector lines.\r\n        * Once you set up the connector lines, Inkscape is happy to work with them as it does with any other connector.\r\n3. Draw a dotted-line rectangle around the satins that should be treated as a unit\r\n  * **Pros**:\r\n    * (mostly) visually obvious\r\n  * **Cons**:\r\n    * harder for Ink/Stitch to parse\r\n    * not as discoverable for the user\r\n    * kinda... weird?\r\n    * the dotted-line box may be visually distracting\r\n4. Link all of the satins together as one single path\r\n  * **Pros**:\r\n    * perhaps the most sensible option of all for the user\r\n  * **Cons**:\r\n    * amplifies the problem in #195 about 100x\r\n      * I'm really not sure how Ink/Stitch could reliably determine which things are rungs and which are rails if there are multiple sets of rails...\r\n\r\nAnyone have any other brilliant ideas?\r\n"},"comment":{"url":"https://api.github.com/repos/inkstitch/inkstitch/issues/comments/407245409","html_url":"https://github.com/inkstitch/inkstitch/issues/214#issuecomment-407245409","issue_url":"https://api.github.com/repos/inkstitch/inkstitch/issues/214","id":407245409,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNzI0NTQwOQ==","user":{"login":"lexelby","id":4446653,"node_id":"MDQ6VXNlcjQ0NDY2NTM=","avatar_url":"https://avatars1.githubusercontent.com/u/4446653?v=4","gravatar_id":"","url":"https://api.github.com/users/lexelby","html_url":"https://github.com/lexelby","followers_url":"https://api.github.com/users/lexelby/followers","following_url":"https://api.github.com/users/lexelby/following{/other_user}","gists_url":"https://api.github.com/users/lexelby/gists{/gist_id}","starred_url":"https://api.github.com/users/lexelby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lexelby/subscriptions","organizations_url":"https://api.github.com/users/lexelby/orgs","repos_url":"https://api.github.com/users/lexelby/repos","events_url":"https://api.github.com/users/lexelby/events{/privacy}","received_events_url":"https://api.github.com/users/lexelby/received_events","type":"User","site_admin":false},"created_at":"2018-07-24T00:56:38Z","updated_at":"2018-07-24T00:56:38Z","author_association":"MEMBER","body":"You've largely got the idea of the algorithm I have in mind for auto-satin.  Here are my notes:\r\n\r\nauto-satin\r\n  * use hierholzer again\r\n  * build graph by duplicating each segment of each satin\r\n  * once you find the final path through the graph:\r\n    * the last traversal of each section is satin\r\n    * all previous traversals are running stitch\r\n  * do a simple path-finding algorithm from start to end to start it off\r\n    * implicitly adding a third duplicate edge along the path\r\n    * or maybe not?  we'll have to see how the pathing comes out\r\n  * break up paths where they intersect with other paths\r\n    * such as the crux of a K\r\n    * perhaps instead, just break paths up into segments ~.5mm long?\r\n      * this might achieve the same effect and be way simpler\r\n  * add jump edges between nearby points such as the center of an X\r\n  * also add doubled jump edges between \"islands\" to form a fully-connected graph\r\n    * e.g. if they auto-satin an entire word at a time, add a jump between and double it to keep the graph eulerian\r\n\r\nThis one's much easier than fill stitch.  We don't really care about the pathing order -- it's going to come out looking fine.  The graph is much smaller and less connected, so the likelihood of a really weird path that goes back and forth all over the place is much lower (I think).  All we really need is a path that gets us from start to end and uses each satin edge at minimum one time.\r\n\r\nFiguring out which edges should be running stitch (underpathing) versus which are satin is really cool: if my eulerian path consumes a given satin edge `x` times, where `x > 1`, then all but the last time through should be running stitch.  Last one's always satin.  Boom, automatic hiding of the underpathing."}}
{"actor":{"display_login":"lexelby"}}