perf: remove no-op AutoNester.Optimize calls from fill pipelines

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-20 20:11:49 -04:00
parent b7c7cecd75
commit c88cec2beb
4 changed files with 1 additions and 13 deletions

View File

@@ -1,5 +1,4 @@
using OpenNest.Engine.Fill;
using OpenNest.Engine.Nfp;
using OpenNest.Geometry;
using System;
using System.Collections.Generic;
@@ -130,9 +129,6 @@ namespace OpenNest
// Compact placed parts toward the origin to close gaps.
Compactor.Settle(allParts, Plate.WorkArea(), Plate.PartSpacing);
// NFP optimization pass — re-place parts using geometry-aware BLF.
allParts = AutoNester.Optimize(allParts, Plate);
return allParts;
}

View File

@@ -49,9 +49,6 @@ namespace OpenNest
// Compact placed parts toward the origin to close gaps.
Compactor.Settle(parts, Plate.WorkArea(), Plate.PartSpacing);
// NFP optimization pass — re-place parts using geometry-aware BLF.
parts = AutoNester.Optimize(parts, Plate);
// Deduct placed quantities from original items.
foreach (var item in items)
{

View File

@@ -1,5 +1,4 @@
using OpenNest.Engine.Fill;
using OpenNest.Engine.Nfp;
using OpenNest.Geometry;
using System;
using System.Collections.Generic;
@@ -123,9 +122,6 @@ namespace OpenNest
}
}
// NFP optimization pass — re-place parts using geometry-aware BLF.
allParts = AutoNester.Optimize(allParts, Plate);
// Deduct placed quantities from original items.
foreach (var item in items)
{

View File

@@ -2,7 +2,6 @@
using OpenNest.CNC;
using OpenNest.Collections;
using OpenNest.Engine.Fill;
using OpenNest.Engine.Nfp;
using OpenNest.Forms;
using OpenNest.Geometry;
using OpenNest.Math;
@@ -961,7 +960,7 @@ namespace OpenNest.Controls
{
var result = engine.Fill(groupParts, workArea, progress, cts.Token);
Compactor.Settle(result, workArea, spacing);
return AutoNester.Optimize(result, workArea, spacing);
return result;
});
if (parts.Count > 0 && (!cts.IsCancellationRequested || progressForm.Accepted))