mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-31 12:41:20 -06:00 
			
		
		
		
	New options: start_perimeters_at_concave_points start_perimeters_at_non_overhang
This commit is contained in:
		
							parent
							
								
									362232ada4
								
							
						
					
					
						commit
						0a7e0ffecf
					
				
					 4 changed files with 39 additions and 6 deletions
				
			
		|  | @ -573,6 +573,20 @@ our $Options = { | |||
|         type    => 'bool', | ||||
|         default => 0, | ||||
|     }, | ||||
|     'start_perimeters_at_concave_points' => { | ||||
|         label   => 'Concave points', | ||||
|         tooltip => 'Prefer to start perimeters at a concave point.', | ||||
|         cli     => 'start-perimeters-at-concave-points!', | ||||
|         type    => 'bool', | ||||
|         default => 0, | ||||
|     }, | ||||
|     'start_perimeters_at_non_overhang' => { | ||||
|         label   => 'Non-overhang points', | ||||
|         tooltip => 'Prefer to start perimeters at non-overhanging points.', | ||||
|         cli     => 'start-perimeters-at-non-overhang!', | ||||
|         type    => 'bool', | ||||
|         default => 0, | ||||
|     }, | ||||
|     'avoid_crossing_perimeters' => { | ||||
|         label   => 'Avoid crossing perimeters', | ||||
|         tooltip => 'Optimize travel moves in order to minimize the crossing of perimeters. This is mostly useful with Bowden extruders which suffer from oozing. This feature slows down both the print and the G-code generation.', | ||||
|  |  | |||
|  | @ -155,9 +155,14 @@ sub extrude_loop { | |||
|      | ||||
|     # find candidate starting points | ||||
|     # start looking for concave vertices not being overhangs | ||||
|     my @concave = $loop->polygon->concave_points; | ||||
|     my @candidates = grep !Boost::Geometry::Utils::point_covered_by_multi_polygon($_, $self->_layer_overhangs), | ||||
|         @concave; | ||||
|     my @concave = (); | ||||
|     if ($Slic3r::Config->start_perimeters_at_concave_points) { | ||||
|         @concave = $loop->polygon->concave_points; | ||||
|     } | ||||
|     my @candidates = (); | ||||
|     if ($Slic3r::Config->start_perimeters_at_non_overhang) { | ||||
|         @candidates = grep !Boost::Geometry::Utils::point_covered_by_multi_polygon($_, $self->_layer_overhangs), @concave; | ||||
|     } | ||||
|     if (!@candidates) { | ||||
|         # if none, look for any concave vertex | ||||
|         @candidates = @concave; | ||||
|  |  | |||
|  | @ -412,7 +412,15 @@ sub build { | |||
|         }, | ||||
|         { | ||||
|             title => 'Quality (slower slicing)', | ||||
|             options => [qw(extra_perimeters avoid_crossing_perimeters)], | ||||
|             options => [qw(extra_perimeters avoid_crossing_perimeters start_perimeters_at_concave_points start_perimeters_at_non_overhang)], | ||||
|             lines => [ | ||||
|                 Slic3r::GUI::OptionsGroup->single_option_line('extra_perimeters'), | ||||
|                 Slic3r::GUI::OptionsGroup->single_option_line('avoid_crossing_perimeters'), | ||||
|                 { | ||||
|                     label   => 'Start perimeters at', | ||||
|                     options => [qw(start_perimeters_at_concave_points start_perimeters_at_non_overhang)], | ||||
|                 }, | ||||
|             ], | ||||
|         }, | ||||
|         { | ||||
|             title => 'Advanced', | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Alessandro Ranellucci
						Alessandro Ranellucci