Commit Graph

243 Commits

Author SHA1 Message Date
Alessandro Ranellucci
9918c1e97d Minor improvements in debug output 2013-10-13 12:12:03 +02:00
Alessandro Ranellucci
9a51964e98 Clean medial axis code and gap fill 2013-09-17 10:37:01 +02:00
Alessandro Ranellucci
09684c67c2 Optimization: Remove useless calls to union() 2013-09-07 00:28:53 +02:00
Alessandro Ranellucci
e02ae0d18a Return Surface objects by reference from SurfaceCollection objects and fix a bug in XS code causing some shell options to be ignored 2013-09-06 18:36:38 +02:00
Alessandro Ranellucci
a49dc603cc Many changes and fixes to remove leaks and return objects by reference 2013-09-03 19:26:58 +02:00
Alessandro Ranellucci
275422fac7 Don't return first_point() and last_point() by reference 2013-09-02 22:33:03 +02:00
Alessandro Ranellucci
c0789506e4 Return objects by reference instead of always cloning 2013-09-02 20:22:20 +02:00
Alessandro Ranellucci
bd7b0e2aed Ported ExtrusionPath::Collection->chained_path 2013-08-29 11:47:59 +02:00
Alessandro Ranellucci
5d6fd7f4d9 Optimizations for better usage of XS code 2013-08-29 01:36:42 +02:00
Alessandro Ranellucci
fb763b0187 Removed dependency on Math::Clipper 2013-08-27 01:26:44 +02:00
Alessandro Ranellucci
da0b85c0d9 Ported ExPolygon->contour and ExPolygon->holes 2013-08-26 23:09:18 +02:00
Alessandro Ranellucci
9cf831b9c5 Ported union_pt() to XS 2013-08-26 18:37:19 +02:00
Alessandro Ranellucci
443d4e52cb Fixed everything in the XS port 2013-08-26 17:58:37 +02:00
Alessandro Ranellucci
fc9cec9d81 Merge branch 'master' into xsdata
Conflicts:
	lib/Slic3r/Layer/Region.pm
	lib/Slic3r/Print/Object.pm
2013-08-25 19:59:42 +02:00
Alessandro Ranellucci
3d6fb1b05c New feature: ability to override specific settings for individual objects in the plater. #344 2013-08-25 14:37:50 +02:00
Alessandro Ranellucci
097912755b Fix handling of dirty models with overlapping facets, where some holes became filled because of wrong slice nesting 2013-08-19 16:53:54 +02:00
Alessandro Ranellucci
fa07c512b4 Merge branch 'master' into xsdata
Conflicts:
	lib/Slic3r/Layer/Region.pm
	lib/Slic3r/Print.pm
	lib/Slic3r/Print/Object.pm
2013-08-16 09:09:56 +02:00
Alessandro Ranellucci
2b36778dc1 Fix a situation where extra perimeters prevented top shell to be fully propagated. #1387 2013-08-13 09:45:33 +02:00
Alessandro Ranellucci
3751e3813c Fix regression causing too much collapsing of infill regions 2013-08-09 16:18:21 +02:00
Alessandro Ranellucci
3427b29a93 Fix wrong slices when many overlapping facets were present in the model 2013-08-08 16:27:41 +02:00
Alessandro Ranellucci
b38cc2c244 Merge branch 'master' into xsdata
Conflicts:
	lib/Slic3r.pm
	lib/Slic3r/ExPolygon.pm
	lib/Slic3r/Fill.pm
	lib/Slic3r/Fill/Rectilinear.pm
	lib/Slic3r/GCode.pm
	lib/Slic3r/GUI/Plater.pm
	lib/Slic3r/Geometry/Clipper.pm
	lib/Slic3r/Layer/Region.pm
	lib/Slic3r/Print.pm
	lib/Slic3r/Print/Object.pm
	lib/Slic3r/TriangleMesh.pm
	t/shells.t
	xs/MANIFEST
2013-08-08 02:10:34 +02:00
Alessandro Ranellucci
2a2d15e422 Fix error after recent change about bridges 2013-07-29 12:15:30 +02:00
Alessandro Ranellucci
1f36406a62 Bugfix: thin bridge anchors were ignored. #304 2013-07-29 11:54:32 +02:00
Alessandro Ranellucci
a145f1b6aa Don't merge adjacent bridges so that more correct angles can be detected for each one 2013-07-26 12:31:44 +02:00
Alessandro Ranellucci
37bf0fa53b Bugfix: medial axis thin wall detection was triggered when not needed 2013-07-26 00:13:24 +02:00
Alessandro Ranellucci
8fe228fcee Smarter ordering of gap fill 2013-07-26 00:03:28 +02:00
Alessandro Ranellucci
e29aca3553 Reapply correct optimization for simplifiying fill_surfaces before performing the offset. #1325 2013-07-20 12:22:41 +02:00
Alessandro Ranellucci
1b285f3f46 Thread-safe integration of ExtrusionPath::Collection 2013-07-18 22:29:12 +02:00
Alessandro Ranellucci
c030e38908 Ported ExtrusionPath::Collection 2013-07-18 19:09:07 +02:00
Alessandro Ranellucci
c7b6818ccf Ported offset() and offset2() 2013-07-17 00:48:29 +02:00
Alessandro Ranellucci
bf8c799685 Ported diff_ex, intersection_ex, union_ex, xor_ex 2013-07-17 00:29:09 +02:00
Alessandro Ranellucci
898007fc36 Port offset_ex() and offset2_ex() to XS 2013-07-16 20:09:53 +02:00
Alessandro Ranellucci
9458c7db97 Fix integration of XS containers 2013-07-16 17:13:01 +02:00
Mark Hindess
b5426ad297 Revert "Optimization: simplify fill_surfaces before the offset operation"
To workaround issue #1325 and possibly #1320.

This reverts commit 3a046e3411.
2013-07-16 10:44:52 +01:00
Alessandro Ranellucci
9b582a11ff Adopt XS containers everywhere (incomplete work) 2013-07-16 09:49:34 +02:00
Alessandro Ranellucci
159a009f96 Fix tests here and there 2013-07-15 15:26:56 +02:00
Alessandro Ranellucci
f612d4c64e Ported ExtrusionPath to XS. Failing test for Surface 2013-07-15 12:14:22 +02:00
Alessandro Ranellucci
7534c1e6d9 Use Slic3r::Surface::Collection for Layer::Region->slices 2013-07-14 15:03:45 +02:00
Alessandro Ranellucci
5885be881c New Slic3r::Surface::Collection class 2013-07-14 14:56:43 +02:00
Alessandro Ranellucci
53e4532f9c Merge branch 'master' into xsdata 2013-07-07 12:58:06 +02:00
Alessandro Ranellucci
3a046e3411 Optimization: simplify fill_surfaces before the offset operation 2013-07-07 12:57:26 +02:00
Alessandro Ranellucci
f7967414e0 Store layer slices and region slices as XS data to save memory and make them shared across threads 2013-07-07 12:54:20 +02:00
Alessandro Ranellucci
cca25c9950 Fix a numerical issue causing failure to detect some bridge anchors 2013-07-06 14:38:53 +02:00
Alessandro Ranellucci
985af5ee56 Merge branch 'newslice' 2013-07-06 12:16:54 +02:00
Alessandro Ranellucci
282c751b0f New option for disabling thin wall detection 2013-07-05 22:10:43 +02:00
Alessandro Ranellucci
8061cc6e30 Optimization in Polyline instantiation 2013-07-05 14:44:41 +02:00
Alessandro Ranellucci
27c421c27f Slight optimization 2013-07-05 14:21:20 +02:00
Alessandro Ranellucci
b266d6217a Skip slow gap detection if we aren't going to fill gaps anyway 2013-07-05 14:17:54 +02:00
Alessandro Ranellucci
4d46ebc6cb Removed useless, slow, code 2013-07-05 14:17:09 +02:00
Alessandro Ranellucci
9a904dc88d Lighter implementation of the slicing algorithm to save memory and time 2013-06-23 12:26:40 +02:00
Alessandro Ranellucci
c03f9f0197 Fixed regression causing wrong direction for inwards move in holes. Includes regression test. #1265 2013-06-23 00:05:08 +02:00
Alessandro Ranellucci
7e875393f5 New algorithm for overhang detection 2013-06-20 20:11:46 +02:00
Alessandro Ranellucci
015580629b Removed wrong optimization causing possible extra retractions while moving in infill space 2013-06-20 19:43:53 +02:00
Alessandro Ranellucci
f7be746599 Disable overhang detection for now 2013-06-19 20:09:58 +02:00
Alessandro Ranellucci
c6ef81fb91 Modify overhang detection algorithm 2013-06-16 18:08:17 +02:00
Alessandro Ranellucci
ac4a0bcdd8 Refactoring: use Slic3r::Geometry::BoundingBox objects everywhere 2013-06-16 12:21:25 +02:00
Alessandro Ranellucci
07407e5dbd Merge branch 'master' into overhang
Conflicts:
	lib/Slic3r/GCode.pm
2013-06-16 10:49:33 +02:00
Alessandro Ranellucci
d0eac88ff9 Reduce vibrations when doing gap fill 2013-06-15 21:27:36 +02:00
Alessandro Ranellucci
8b48d79563 Improve zigzag gap fill. #1234 2013-06-15 21:10:04 +02:00
Alessandro Ranellucci
09b81ad027 Fix typo causing regression in island ordering. #1211 2013-06-03 21:27:09 +02:00
Alessandro Ranellucci
bbb190dc68 Generate infill using each object's bounding_box instead of full print. #1177 2013-05-19 11:35:41 +02:00
Alessandro Ranellucci
a94d26b1ce Fix overhang detection for contours 2013-05-15 10:50:38 +02:00
Alessandro Ranellucci
575127151b New algorithm for overhang detection 2013-05-14 20:19:42 +02:00
Alessandro Ranellucci
d2425748a3 Code cleanup and remove arc compensation code 2013-05-13 13:18:58 +02:00
Alessandro Ranellucci
5efa409c7c Move gap fill to its own method 2013-05-13 13:07:22 +02:00
Alessandro Ranellucci
1d94618c5e Correctly detect external hole perimeters 2013-05-13 12:52:57 +02:00
Alessandro Ranellucci
ca549cd2fe Perimeters refactoring complete 2013-05-11 21:30:26 +02:00
Alessandro Ranellucci
67b24efd49 Incomplete work - still wrong order 2013-05-11 21:05:29 +02:00
Alessandro Ranellucci
df62c25c8f One more offset_ex() optimization 2013-05-11 09:39:38 +02:00
Alessandro Ranellucci
0e100827f8 Avoid useless looping and usage of ExPolygons 2013-05-11 09:35:33 +02:00
Alessandro Ranellucci
6b8894cf9a Rename ex_int_offset2 to offset2_ex 2013-05-10 13:56:29 +02:00
Alessandro Ranellucci
c2301c5796 Don't extend solid layers when fill density is 0 2013-04-29 15:55:50 +02:00
Alessandro Ranellucci
17f76c4951 Move bridge detection to its own method 2013-04-18 18:43:46 +02:00
Alessandro Ranellucci
e088d9b3f7 Cache Slic3r::Fill object 2013-04-18 18:40:59 +02:00
Alessandro Ranellucci
312bb285a0 Fix initialization of Rectilinear filler 2013-04-18 18:37:46 +02:00
Alessandro Ranellucci
b160feacfd Merge branch 'master' into clipper-optimizations 2013-04-18 17:36:42 +02:00
Alessandro Ranellucci
7e51cbcf69 Allow 0.1mm slots. #959 #1056 2013-04-04 01:24:40 +02:00
Alessandro Ranellucci
1187f4846d Some Clipper optimizations 2013-03-31 19:40:25 +02:00
Alessandro Ranellucci
d4119b0eb1 Better bridge direction detection. #1068 2013-03-29 23:49:58 +01:00
Alessandro Ranellucci
1b79b1cb20 Refactoring: use the clone() method for inflating Surface objects 2013-03-29 19:18:06 +01:00
Alessandro Ranellucci
aae9625a13 Bugfix: solid-infill-below-area wasn't ignored when fill_density = 0, causing solid layers here and there. #1049 2013-03-26 15:47:40 +01:00
Alessandro Ranellucci
7ec6c6ffba Lower 0.5*w to 0.4*w to fill finer gaps. #1057 2013-03-19 16:08:19 +01:00
Alessandro Ranellucci
35bd5a3423 New --solid-infill-extrusion-width option 2013-03-17 00:02:31 +01:00
Alessandro Ranellucci
db2e76a0df New option to change perimeter order. #534 2013-03-16 18:56:49 +01:00
Alessandro Ranellucci
33b40eda18 Always fix self-intersecting polygons that Douglas-Peucker might return 2013-03-16 18:42:56 +01:00
Alessandro Ranellucci
b7945ac790 Finished new extra perimeters implementation 2013-03-11 14:23:16 +01:00
Alessandro Ranellucci
caa79583ff Tiny optimization 2013-03-09 17:08:17 +01:00
Alessandro Ranellucci
fa41e15c68 Fixed regression causing thin walls to be processed twice, thus producing overlapping straight paths and zigzag. #1035 2013-03-09 17:07:11 +01:00
Alessandro Ranellucci
2f192bddca Make tests happy 2013-03-07 16:24:25 +01:00
Alessandro Ranellucci
97e864699e New top-infill-extrusion-width option 2013-03-07 16:00:58 +01:00
Alessandro Ranellucci
36d24ccb0b Infill refactoring and cleanup complete 2013-03-07 15:47:32 +01:00
Alessandro Ranellucci
d928f005e6 Some incomplete work for cleaner infill logic 2013-03-05 20:03:46 +01:00
Mike Sheldrake
28467b68e0 typo - fix wrong bridge direction #621
fixes two out of three reported in #621 (but not the first one)
likely the same issue in #706 and #1003
2013-02-27 15:16:07 -08:00
Alessandro Ranellucci
919d1131f8 Use nearest-neighbor search for internal perimeters too. #1025 2013-02-27 11:04:14 +01:00
Alessandro Ranellucci
a9090688f9 Refactor bridge flow to Slic3r::Flow::Bridge class 2013-02-27 10:43:50 +01:00
Alessandro Ranellucci
08a72c0824 Use bridge math for the first solid infill layer above sparse infill. #240 2013-02-23 21:39:13 +01:00
Alessandro Ranellucci
0634437364 Keep the full geometries in $layer->slices, including thin walls 2013-02-23 18:21:29 +01:00
Alessandro Ranellucci
28638019ae Bugfix: perimeter/infill overlap was calculated regardless of the infill extrusion width. #994 2013-02-22 18:23:23 +01:00
Alessandro Ranellucci
bec2371604 Fix regression introduced in 91bcfc8a74 2013-02-22 16:56:43 +01:00
Alessandro Ranellucci
91bcfc8a74 Remove $Slic3r::flow and $Slic3r::first_layer_flow 2013-02-22 16:08:11 +01:00
Alessandro Ranellucci
b9c84490b8 Get rid of most calls to $Slic3r::flow 2013-02-19 12:37:26 +01:00
Alessandro Ranellucci
cac79c0575 New option to only infill where strictly needed for supporting ceilings 2013-02-09 23:36:32 +01:00
Alessandro Ranellucci
26a3cd5542 Refactor chained_path(), add chained_path_items() and chained_path_points() 2013-02-06 12:03:53 +01:00
Alessandro Ranellucci
090e3b1fe3 Rename shortest_path to chained_path, which reflects its algorithm more correctly 2013-02-05 17:27:45 +01:00
Alessandro Ranellucci
ecc7e4560e Don't fill gaps if fill density is 0. #915 2013-01-17 10:39:05 +01:00
Mike Sheldrake
73aae07e74 842, 847 slightly enlarge a clip polygon to counteract integer truncation
Geomery in referenced issues triggered Clipper problems, but also
pointed to a situation where integer truncation (as coordinates pass
into Clipper) might be shrinking a clip polygon in a way that leaves
degenerate or unwanted thin clip results. Growing the clip polygon by 2
is expected to overcome any issues caused by truncation of floats.
2013-01-11 10:15:42 -08:00
Alessandro Ranellucci
141a8d3989 Bugfix: some holes being closed incorrectly. #858 2012-12-30 17:57:30 +01:00
Alessandro Ranellucci
6e6bc74636 Added failing test case for troubleshooting unexpected filled holes. #858 2012-12-30 16:27:20 +01:00
Alessandro Ranellucci
0da71dbdfa Fix regression causing wrong number of solid shells when using fill_density = 0 (includes regression test) 2012-12-23 20:20:17 +01:00
Alessandro Ranellucci
15f07197d8 Don't store ->surfaces anymore. Save memory, save time 2012-12-22 23:57:39 +01:00
Alessandro Ranellucci
b70404bb23 Disable gap filling if gap fill speed is set to zero 2012-12-17 19:55:25 +01:00
Alessandro Ranellucci
283809f5c2 No need for a role to identify small perimeters 2012-12-05 10:47:41 +01:00
Alessandro Ranellucci
8ae96a8868 Only apply vibration limit to gaps fill while it's not very mature to work with long segments 2012-11-21 19:27:38 +01:00
Alessandro Ranellucci
cd892fdce8 Connect zigzag gaps fill paths to benefit from simplification 2012-11-19 18:57:42 +01:00
Alessandro Ranellucci
c99ff0cfe2 Apply Douglas-Peucker to all paths before generating G-code 2012-11-18 17:38:08 +01:00
Alessandro Ranellucci
a1a12ffe8e Allow setting top-solid-layers and bottom-solid-layers to 0 independently 2012-11-16 12:37:47 +01:00
Alessandro Ranellucci
b625c3b2b2 Simplify gaps fills to avoid some shaking 2012-11-16 10:47:42 +01:00
Alessandro Ranellucci
68e1edab80 Require Math::Clipper 1.14 and increase scale factor for offset(). #720 2012-11-05 00:17:46 +01:00
Alessandro Ranellucci
93a8391e18 Alternate gaps fill direction 2012-11-01 11:53:18 +01:00
Alessandro Ranellucci
37c0b45187 Detect gaps even after the desired number of perimeters has been generated 2012-11-01 11:51:52 +01:00
Alessandro Ranellucci
cb4ede7f9e Do not pass the Print object to SVG::output anymore 2012-11-01 11:34:53 +01:00
Alessandro Ranellucci
554d10c854 Only put ExtrusionPath objects in ExtrusionPath::Collection (no ExtrusionLoop objects) 2012-10-31 19:08:29 +01:00
Alessandro Ranellucci
44d91774a6 Get rid of useless Slic3r::Fill instances 2012-10-30 15:38:17 +01:00
Alessandro Ranellucci
1ecadc10fb Fixed regression causing one perimeter to be generated even when perimeters where set to 0. #759 2012-10-28 19:27:54 +01:00
Alessandro Ranellucci
f35cdef2aa Renamed ExtrusionPath->depth_layers to height 2012-10-28 14:22:51 +01:00
Alessandro Ranellucci
f9b6caaecb Bugfix, last commit was incomplete 2012-10-28 12:22:30 +01:00
Alessandro Ranellucci
a0fe93e8cf Bugfix: sometimes first layer extrusion width was not applied 2012-10-28 10:28:40 +01:00
Alessandro Ranellucci
49916b6178 Revert 2bcac88683 by setting the scale factor manually to 1. #720 2012-10-27 22:09:22 +02:00
Alessandro Ranellucci
f9e20db156 Update t/dynamic.t 2012-10-27 21:20:32 +02:00
Alessandro Ranellucci
cee3864fc9 Independently set number of top/bottom solid layers. #676 2012-10-25 12:21:04 +02:00
Alessandro Ranellucci
f0d2b0e5ea Avoid overlapping regions (thanks Mike Sheldrake!). #726 2012-10-24 16:46:40 +02:00
Alessandro Ranellucci
1c50c8a401 Merge branch 'dynamic-flow' 2012-10-24 16:19:13 +02:00
Alessandro Ranellucci
6beaf5e597 New faster algorithm for filling gaps, while we work on a new medial axis implementation 2012-10-24 16:17:09 +02:00
Alessandro Ranellucci
1445820673 External perimeter first on bottom layer when brim is enabled. #761 2012-10-24 12:04:44 +02:00
Alessandro Ranellucci
19e77a28a1 Merge branch 'master' into dynamic-flow 2012-10-24 10:55:57 +02:00
Alessandro Ranellucci
b92642459f Merge branch 'master' into dynamic-flow
Conflicts:
	lib/Slic3r/Flow.pm
	lib/Slic3r/Layer.pm
2012-10-04 15:23:19 +02:00
Mike Sheldrake
2bcac88683 Increase scale factor for Clipper::offset
A default scale of 1 was being calculated most of the time. That's too
low to avoid artifacts from offsetting concave curves. Setting scale to
a default of 100000 eliminates artifacts in the test cases in issues
#700, #702 and #703. There is a risk of large point proliferation with
this scale in combination with the JT_ROUND option, but in the four
places where that option is used, scale is already explicitly set to a
safer low value.
2012-09-27 05:50:54 -07:00
Alessandro Ranellucci
bbe0a45b58 Optimization: cache scaled flow width and spacing 2012-09-23 03:03:08 +02:00
Alessandro Ranellucci
ec0d3987db Rename materials to regions 2012-09-23 02:52:31 +02:00
Alessandro Ranellucci
e696764af8 Assign extruders and flows to materials 2012-09-23 02:40:25 +02:00
Alessandro Ranellucci
e2ab340edb Fix positioning and other things 2012-09-22 21:03:57 +02:00
Alessandro Ranellucci
d488afd243 More work (breaks centering and internal surfaces detection) 2012-09-22 19:38:25 +02:00
Alessandro Ranellucci
02356fd613 Large refactoring to allow processing multimaterial files 2012-09-22 19:04:36 +02:00