fix(build): convert Point3 lerp results and polyline points to Point in Fill.cpp

This commit is contained in:
thysson2701
2026-07-21 15:31:48 +02:00
parent f81987e6cc
commit e15298249a

View File

@@ -9814,11 +9814,11 @@ static bool top_surface_image_append_recolored_perimeter_path(ExtrusionEntitiesP
for (int step = 0; step < steps; ++step) {
const double t0 = double(step) / double(steps);
const double t1 = double(step + 1) / double(steps);
const Point q0 = lerp(p0, p1, t0);
const Point q1 = lerp(p0, p1, t1);
const Point q0 = lerp(p0, p1, t0).to_point();
const Point q1 = lerp(p0, p1, t1).to_point();
if (q0 == q1)
continue;
const Point qm = lerp(p0, p1, 0.5 * (t0 + t1));
const Point qm = lerp(p0, p1, 0.5 * (t0 + t1)).to_point();
int extruder_override = top_surface_image_perimeter_override_at_point(qm, masks);
if (extruder_override >= 0 && len_mm / double(steps) < min_run_mm - EPSILON)
extruder_override = -1;
@@ -10866,8 +10866,8 @@ static ExtrusionPaths top_surface_image_split_path(const ExtrusionPath &path,
for (size_t point_idx = 1; point_idx < path.polyline.points.size(); ++point_idx) {
if ((point_idx & 63) == 1)
check_canceled(throw_if_canceled);
const Point p0 = path.polyline.points[point_idx - 1];
const Point p1 = path.polyline.points[point_idx];
const Point p0 = path.polyline.points[point_idx - 1].to_point();
const Point p1 = path.polyline.points[point_idx].to_point();
const double len_mm = unscale<double>(p0.distance_to(p1));
if (!std::isfinite(len_mm) || len_mm <= EPSILON)
continue;