mirror of
https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git
synced 2026-07-30 05:14:30 +03:00
Unite cancel callback and status function
This commit is contained in:
@@ -19,19 +19,19 @@ namespace sla {
|
||||
* @param accuracy The optimization accuracy from 0.0f to 1.0f. Currently,
|
||||
* the nlopt genetic optimizer is used and the number of iterations is
|
||||
* accuracy * 100000. This can change in the future.
|
||||
* @param statuscb A status indicator callback called with the unsigned
|
||||
* @param statuscb A status indicator callback called with the int
|
||||
* argument spanning from 0 to 100. May not reach 100 if the optimization finds
|
||||
* an optimum before max iterations are reached.
|
||||
* @param stopcond A function that if returns true, the search process will be
|
||||
* terminated and the best solution found will be returned.
|
||||
* an optimum before max iterations are reached. It should return a boolean
|
||||
* signaling if the operation may continue (true) or not (false). A status
|
||||
* value lower than 0 shall not update the status but still return a valid
|
||||
* continuation indicator.
|
||||
*
|
||||
* @return Returns the rotations around each axis (x, y, z)
|
||||
*/
|
||||
Vec2d find_best_rotation(
|
||||
const SLAPrintObject& modelobj,
|
||||
float accuracy = 1.0f,
|
||||
std::function<void(unsigned)> statuscb = [] (unsigned) {},
|
||||
std::function<bool()> stopcond = [] () { return false; }
|
||||
std::function<bool(int)> statuscb = [] (int) { return true; }
|
||||
);
|
||||
|
||||
double get_model_supportedness(const SLAPrintObject &mesh,
|
||||
|
||||
Reference in New Issue
Block a user