enh: Remap filament (#12016)

# Description

This Pr improve the Remap filament feature.
It now recognizes the filaments used in the object and makes them available only for remapping.
You can also see a small preview, showing which color will be changed to which.

Before PR:
![before](https://github.com/user-attachments/assets/e13f3622-2420-478e-a22c-9d7cdc12b24c)


After PR:
![after](https://github.com/user-attachments/assets/38d94230-f5bd-45f2-b9cd-c5bdff5ee801)
This commit is contained in:
tome9111991
2026-01-26 08:21:18 +01:00
committed by GitHub
parent e81e7b9a23
commit 8abf0f761d
4 changed files with 197 additions and 46 deletions

View File

@@ -2197,4 +2197,15 @@ bool TriangleSelector::Capsule2D::is_edge_inside_cursor(const Triangle &tr, cons
return false;
}
// ORCA: Helper to extract used states from serialized data
std::vector<EnforcerBlockerType> TriangleSelector::extract_used_facet_states(const TriangleSplittingData &data)
{
std::vector<EnforcerBlockerType> out;
for (size_t i = 0; i < data.used_states.size(); ++i) {
if (data.used_states[i])
out.push_back(static_cast<EnforcerBlockerType>(i));
}
return out;
}
} // namespace Slic3r