diff --git a/src/libslic3r/GCode.cpp b/src/libslic3r/GCode.cpp index 464e1516ac3..74f1da5683b 100644 --- a/src/libslic3r/GCode.cpp +++ b/src/libslic3r/GCode.cpp @@ -13803,9 +13803,9 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description, total_length = l.length() * SCALING_FACTOR; } gcode += m_writer.set_speed(last_set_speed, "", comment); - Point prev_point_model = new_points[0].p; + Point prev_point_model = new_points[0].p.to_point(); if (outer_wall_gradient_modulated_path && new_points.size() > 1) { - const Line first_line(new_points[0].p, new_points[1].p); + const Line first_line(new_points[0].p.to_point(), new_points[1].p.to_point()); const OuterWallGradientSurfaceCoord first_surface_coord = halftone_surface_coord_for_source_distance(first_line.length() * SCALING_FACTOR * 0.5); const OuterWallGradientSegmentMod first_mod = @@ -13843,7 +13843,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description, for (size_t i = 1; i < new_points.size(); ++i) { const ProcessedPoint &processed_point = new_points[i]; const ProcessedPoint &pre_processed_point = new_points[i - 1]; - const Line parent_source_line(pre_processed_point.p, processed_point.p); + const Line parent_source_line(pre_processed_point.p.to_point(), processed_point.p.to_point()); const double parent_source_length_mm = parent_source_line.length() * SCALING_FACTOR; const double safe_parent_source_length_mm = std::isfinite(parent_source_length_mm) ? std::max(0.0, parent_source_length_mm) : 0.0; @@ -14054,7 +14054,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description, std::string tempDescription = description; const ProcessedPoint &processed_point = new_points[i]; const ProcessedPoint &pre_processed_point = new_points[i-1]; - const Line parent_source_line(pre_processed_point.p, processed_point.p); + const Line parent_source_line(pre_processed_point.p.to_point(), processed_point.p.to_point()); const double parent_source_length_mm = parent_source_line.length() * SCALING_FACTOR; const double safe_parent_source_length_mm = std::isfinite(parent_source_length_mm) ? std::max(0.0, parent_source_length_mm) : 0.0; @@ -14071,7 +14071,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description, dynamic_line_modulation ? dynamic_modulation_for_line(parent_source_line, segment_surface_coord) : segment_modulation_at(i - 1); - const Point processed_target_point = make_shifted_point(processed_point.p, segment_mod.shift_dx, segment_mod.shift_dy); + const Point processed_target_point = make_shifted_point(processed_point.p.to_point(), segment_mod.shift_dx, segment_mod.shift_dy); Vec2d p = this->point_to_gcode_quantized(processed_target_point); if (!is_reasonable_quantized_gcode_point_for_gcode(p)) continue; @@ -14162,7 +14162,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, std::string description, outer_wall_gradient_dynamic_ctx.vertex_color_match_mode && outer_wall_gradient_dynamic_ctx.high_resolution_texture_sampling; if (high_res_dynamic_subsegments) { - const Line parent_line(pre_processed_point.p, processed_point.p); + const Line parent_line(pre_processed_point.p.to_point(), processed_point.p.to_point()); const double modulation_step_mm = outer_wall_gradient_dynamic_ctx.dithering_enabled ? std::clamp(double(outer_wall_gradient_dynamic_ctx.dither_pitch_mm), 0.04, 0.12) :