{"action":"created","issue":{"url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/395","repository_url":"https://api.github.com/repos/Ultimaker/CuraEngine","labels_url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/395/labels{/name}","comments_url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/395/comments","events_url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/395/events","html_url":"https://github.com/Ultimaker/CuraEngine/issues/395","id":180053347,"number":395,"title":"feature request: oversize skin area","user":{"login":"sjoerdtimmer","id":633834,"avatar_url":"https://avatars.githubusercontent.com/u/633834?v=3","gravatar_id":"","url":"https://api.github.com/users/sjoerdtimmer","html_url":"https://github.com/sjoerdtimmer","followers_url":"https://api.github.com/users/sjoerdtimmer/followers","following_url":"https://api.github.com/users/sjoerdtimmer/following{/other_user}","gists_url":"https://api.github.com/users/sjoerdtimmer/gists{/gist_id}","starred_url":"https://api.github.com/users/sjoerdtimmer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjoerdtimmer/subscriptions","organizations_url":"https://api.github.com/users/sjoerdtimmer/orgs","repos_url":"https://api.github.com/users/sjoerdtimmer/repos","events_url":"https://api.github.com/users/sjoerdtimmer/events{/privacy}","received_events_url":"https://api.github.com/users/sjoerdtimmer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-29T13:45:03Z","updated_at":"2016-09-29T15:57:11Z","closed_at":null,"body":"Because some plastics tend to curl up when skin is printed on top of (sparse) infill it would be good if skin were to protrude a little further inside than strictly necessary to support the walls of higher layers.\r\n\r\nThis is my suggestion to achieve something like that:\r\n```\r\ndiff --git a/src/skin.cpp b/src/skin.cpp\r\nindex 8846b2d..3c75f1c 100644\r\n--- a/src/skin.cpp\r\n+++ b/src/skin.cpp\r\n@@ -94,6 +94,11 @@ void generateSkinAreas(int layer_nr, SliceMeshStorage& mesh, const int innermost\r\n             }\r\n         }\r\n         \r\n+        // increase size of upskin to better support walls\r\n+        // we grow it at first, and then cut it back to within the bounds of the innermost offset\r\n+        // 4 is a heuristic, should be made configureable\r\n+        upskin = upskin.offset(4*innermost_wall_line_width).intersection(part.insets.back().offset(-innermost_wall_line_width / 2));\r\n+\r\n         Polygons skin = upskin.unionPolygons(downskin);\r\n         \r\n         skin.removeSmallAreas(MIN_AREA_SIZE);\r\n```\r\n\r\nThis enlarges the skin area by 4 line widths. This should of course be made configurable.\r\nIt would be even better to stretch skin to the next infill line. However, that would require heavy integration between infill and skin generation while the above is a simple onelines.\r\n\r\nThe diff works for me but it is not extensively tested. I don't foresee any problems but I did not try in combination with all possible options or all kinds of weird input stl's. \r\n"},"comment":{"url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/comments/250509034","html_url":"https://github.com/Ultimaker/CuraEngine/issues/395#issuecomment-250509034","issue_url":"https://api.github.com/repos/Ultimaker/CuraEngine/issues/395","id":250509034,"user":{"login":"BagelOrb","id":8895761,"avatar_url":"https://avatars.githubusercontent.com/u/8895761?v=3","gravatar_id":"","url":"https://api.github.com/users/BagelOrb","html_url":"https://github.com/BagelOrb","followers_url":"https://api.github.com/users/BagelOrb/followers","following_url":"https://api.github.com/users/BagelOrb/following{/other_user}","gists_url":"https://api.github.com/users/BagelOrb/gists{/gist_id}","starred_url":"https://api.github.com/users/BagelOrb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BagelOrb/subscriptions","organizations_url":"https://api.github.com/users/BagelOrb/orgs","repos_url":"https://api.github.com/users/BagelOrb/repos","events_url":"https://api.github.com/users/BagelOrb/events{/privacy}","received_events_url":"https://api.github.com/users/BagelOrb/received_events","type":"User","site_admin":false},"created_at":"2016-09-29T15:57:11Z","updated_at":"2016-09-29T15:57:11Z","body":"I can think of the following problems:\r\n1. a nearly vertical wall gets a 4 line width thick piece of 'top skin'\r\n2. it's computationally quite expensive to do another 2 offsets and an intersection on each part\r\n\r\nIf you can get the correct result by reordering existing code and/or changing an offset which is already being applied I would be very happy.\r\nYou could cache the `part.insets.back().offset(-innermost_wall_line_width / 2)` which is already computed above....\r\n\r\nI call such hacking with offsets and intersections \"offset magic\".\r\nThe whole support system thrives on offset magic!"}}
{"actor":{"display_login":"BagelOrb"}}