Fix Disabled acceleration control still applies to print

supermerill/SuperSlicer#1537
This commit is contained in:
supermerill 2021-09-26 16:41:39 +02:00
parent 22b2d4692b
commit 18504bff9c
2 changed files with 3 additions and 3 deletions

View File

@ -3859,10 +3859,10 @@ std::string GCode::_before_extrude(const ExtrusionPath &path, const std::string
std::string description{ description_in };
// adjust acceleration, inside the travel to set the deceleration
// adjust acceleration, inside the travel to set the deceleration (unless it's deactivated)
double acceleration = get_default_acceleration(m_config);
double travel_acceleration = m_writer.get_acceleration();
{
if(acceleration > 0){
if (this->on_first_layer() && m_config.first_layer_acceleration.value > 0) {
acceleration = m_config.first_layer_acceleration.get_abs_value(acceleration);
} else if (m_config.perimeter_acceleration.value > 0 && is_perimeter(path.role())) {

View File

@ -21,7 +21,7 @@ public:
GCodeWriter() :
multiple_extruders(false), m_extrusion_axis("E"), m_tool(nullptr),
m_single_extruder_multi_material(false),
m_last_acceleration(0), m_max_acceleration(0), m_last_fan_speed(0),
m_last_acceleration(0), m_current_acceleration(0), m_max_acceleration(0), m_last_fan_speed(0),
m_last_bed_temperature(0), m_last_bed_temperature_reached(true),
m_lifted(0)
{}