diff --git a/lib/Slic3r.pm b/lib/Slic3r.pm index 5bf8bb306..38084eaf6 100644 --- a/lib/Slic3r.pm +++ b/lib/Slic3r.pm @@ -132,7 +132,7 @@ our $support_material_threshold = 45; our $support_material_pattern = 'rectilinear'; our $support_material_spacing = 2.5; our $support_material_angle = 0; -our $support_material_tool = 0; +our $support_material_extruder = 0; our $start_gcode = "G28 ; home all axes"; our $end_gcode = <<"END"; M104 S0 ; turn off temperature diff --git a/lib/Slic3r/Config.pm b/lib/Slic3r/Config.pm index cd82a5eed..417dbc59c 100644 --- a/lib/Slic3r/Config.pm +++ b/lib/Slic3r/Config.pm @@ -320,12 +320,11 @@ our $Options = { cli => 'support-material-angle=i', type => 'i', }, - 'support_material_tool' => { + 'support_material_extruder' => { label => 'Extruder', - cli => 'support-material-tool=i', - type => 'select', - values => [0,1], - labels => [qw(Primary Secondary)], + cli => 'support-material-extruder=i', + type => 'i', + aliases => [qw(support_material_tool)], }, 'start_gcode' => { label => 'Start G-code', diff --git a/lib/Slic3r/GUI/SkeinPanel.pm b/lib/Slic3r/GUI/SkeinPanel.pm index 77bbfc84f..7e57f6760 100644 --- a/lib/Slic3r/GUI/SkeinPanel.pm +++ b/lib/Slic3r/GUI/SkeinPanel.pm @@ -87,7 +87,7 @@ sub new { }, support_material => { title => 'Support material', - options => [qw(support_material support_material_threshold support_material_pattern support_material_spacing support_material_angle support_material_tool)], + options => [qw(support_material support_material_threshold support_material_pattern support_material_spacing support_material_angle support_material_extruder)], }, ); $self->{panels} = \%panels; diff --git a/lib/Slic3r/Print.pm b/lib/Slic3r/Print.pm index ecf811d8d..5a2fb98e4 100644 --- a/lib/Slic3r/Print.pm +++ b/lib/Slic3r/Print.pm @@ -510,7 +510,7 @@ sub write_gcode { my $gcodegen = Slic3r::GCode->new; my $min_print_speed = 60 * $Slic3r::min_print_speed; my $dec = $gcodegen->dec; - if ($Slic3r::support_material && $Slic3r::support_material_tool > 0) { + if ($Slic3r::support_material && $Slic3r::support_material_extruder > 0) { print $fh $gcodegen->set_tool(0); } print $fh $gcodegen->set_fan(0, 1) if $Slic3r::cooling && $Slic3r::disable_fan_first_layers; @@ -601,12 +601,12 @@ sub write_gcode { # extrude support material if ($layer->support_fills) { - $gcode .= $gcodegen->set_tool($Slic3r::support_material_tool) - if $Slic3r::support_material_tool > 0; + $gcode .= $gcodegen->set_tool($Slic3r::support_material_extruder) + if $Slic3r::support_material_extruder > 0; $gcode .= $gcodegen->extrude_path($_, 'support material') for $layer->support_fills->shortest_path($gcodegen->last_pos); $gcode .= $gcodegen->set_tool(0) - if $Slic3r::support_material_tool > 0; + if $Slic3r::support_material_extruder > 0; } } return if !$gcode;