Skip to content

Commit

Permalink
New First layer flow ratio option. #182
Browse files Browse the repository at this point in the history
  • Loading branch information
alranel committed Jan 30, 2012
1 parent eb33c03 commit 99ef086
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/Slic3r.pm
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ our $infill_every_layers = 1;

# flow options
our $extrusion_width_ratio = 0;
our $first_layer_flow_ratio = 1;
our $bridge_flow_ratio = 1;
our $overlap_factor = 0.5;
our $flow_width;
Expand Down
5 changes: 5 additions & 0 deletions lib/Slic3r/Config.pm
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,11 @@ our $Options = {
cli => 'extrusion-width-ratio=f',
type => 'f',
},
'first_layer_flow_ratio' => {
label => 'First layer flow ratio',
cli => 'first-layer-flow-ratio=f',
type => 'f',
},
'bridge_flow_ratio' => {
label => 'Bridge flow ratio',
cli => 'bridge-flow-ratio=f',
Expand Down
1 change: 1 addition & 0 deletions lib/Slic3r/Extruder.pm
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ sub extrude_path {
* $area
* $Slic3r::extrusion_multiplier
* (4 / (($Slic3r::filament_diameter ** 2) * PI));
$e *= $Slic3r::first_layer_flow_ratio if $self->layer->id == 0;

# extrude arc or line
$self->print_feed_rate(
Expand Down
2 changes: 1 addition & 1 deletion lib/Slic3r/GUI/SkeinPanel.pm
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ sub new {
},
extrusion => {
title => 'Extrusion',
options => [qw(extrusion_width_ratio bridge_flow_ratio)],
options => [qw(extrusion_width_ratio first_layer_flow_ratio bridge_flow_ratio)],
},
output => {
title => 'Output',
Expand Down
2 changes: 2 additions & 0 deletions slic3r.pl
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,8 @@ sub usage {
--extrusion-width-ratio
Calculate the extrusion width as the layer height multiplied by
this value (> 0, default: calculated automatically)
--first-layer-flow-ratio
Multiplier for extrusion of first layer (> 0, default: $Slic3r::first_layer_flow_ratio)
--bridge-flow-ratio Multiplier for extrusion when bridging (> 0, default: $Slic3r::bridge_flow_ratio)
EOF
Expand Down

0 comments on commit 99ef086

Please sign in to comment.