Skip to content

Commit

Permalink
Revert "Disable small area flow compensation on first layer (Fixes So…
Browse files Browse the repository at this point in the history
…ftFever#4617) (SoftFever#5838)"

This reverts commit 7707685.
  • Loading branch information
vovodroid committed Sep 21, 2024
1 parent 216bbf9 commit e6b98cc
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/libslic3r/GCode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5612,8 +5612,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
continue;
path_length += line_length;
auto dE = e_per_mm * line_length;
if (!this->on_first_layer() && m_small_area_infill_flow_compensator
&& m_config.small_area_infill_flow_compensation.value) {
if (m_small_area_infill_flow_compensator && m_config.small_area_infill_flow_compensation.value) {
auto oldE = dE;
dE = m_small_area_infill_flow_compensator->modify_flow(line_length, dE, path.role());

Expand Down Expand Up @@ -5654,8 +5653,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
if (line_length < EPSILON)
continue;
auto dE = e_per_mm * line_length;
if (!this->on_first_layer() && m_small_area_infill_flow_compensator
&& m_config.small_area_infill_flow_compensation.value) {
if (m_small_area_infill_flow_compensator && m_config.small_area_infill_flow_compensation.value) {
auto oldE = dE;
dE = m_small_area_infill_flow_compensator->modify_flow(line_length, dE, path.role());

Expand All @@ -5678,8 +5676,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
continue;
const Vec2d center_offset = this->point_to_gcode(arc.center) - this->point_to_gcode(arc.start_point);
auto dE = e_per_mm * arc_length;
if (!this->on_first_layer() && m_small_area_infill_flow_compensator
&& m_config.small_area_infill_flow_compensation.value) {
if (m_small_area_infill_flow_compensator && m_config.small_area_infill_flow_compensation.value) {
auto oldE = dE;
dE = m_small_area_infill_flow_compensator->modify_flow(arc_length, dE, path.role());

Expand Down Expand Up @@ -5817,8 +5814,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description,
last_set_speed = F;
}
auto dE = e_per_mm * line_length;
if (!this->on_first_layer() && m_small_area_infill_flow_compensator
&& m_config.small_area_infill_flow_compensation.value) {
if (m_small_area_infill_flow_compensator && m_config.small_area_infill_flow_compensation.value) {
auto oldE = dE;
dE = m_small_area_infill_flow_compensator->modify_flow(line_length, dE, path.role());

Expand Down

0 comments on commit e6b98cc

Please sign in to comment.