mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-24 01:01:15 -06:00
Add throw_on_cancel and statusfn into QEC
This commit is contained in:
parent
c00dca7810
commit
e26bffadd8
3 changed files with 52 additions and 22 deletions
|
|
@ -3,6 +3,7 @@
|
|||
// inspiration: https://github.com/sp4cerat/Fast-Quadric-Mesh-Simplification
|
||||
|
||||
#include <cstdint>
|
||||
#include <functional>
|
||||
#include "TriangleMesh.hpp"
|
||||
|
||||
namespace Slic3r {
|
||||
|
|
@ -14,10 +15,14 @@ namespace Slic3r {
|
|||
/// <param name="triangle_count">Wanted triangle count.</param>
|
||||
/// <param name="max_error">Maximal Quadric for reduce.
|
||||
/// When nullptr then max float is used
|
||||
/// Output: Last used ErrorValue to collapse edge
|
||||
/// </param>
|
||||
void its_quadric_edge_collapse(indexed_triangle_set &its,
|
||||
uint32_t triangle_count = 0,
|
||||
float * max_error = nullptr);
|
||||
/// Output: Last used ErrorValue to collapse edge</param>
|
||||
/// <param name="throw_on_cancel">Could stop process of calculation.</param>
|
||||
/// <param name="statusfn">Give a feed back to user about progress.</param>
|
||||
void its_quadric_edge_collapse(
|
||||
indexed_triangle_set & its,
|
||||
uint32_t triangle_count = 0,
|
||||
float * max_error = nullptr,
|
||||
std::function<void(void)> throw_on_cancel = nullptr,
|
||||
std::function<void(int)> statusfn = nullptr);
|
||||
|
||||
} // namespace Slic3r
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue