Tech ENABLE_ALLOW_NEGATIVE_Z -> Added threshold to detect if an object is sinking

This commit is contained in:
enricoturri1966 2021-06-08 10:07:47 +02:00
parent 1f29a2593b
commit 1c35dfe591
6 changed files with 19 additions and 11 deletions

View file

@ -536,7 +536,7 @@ bool GLVolume::is_sinking() const
#endif // DISABLE_ALLOW_NEGATIVE_Z_FOR_SLA
return false;
const BoundingBoxf3& box = transformed_convex_hull_bounding_box();
return box.min(2) < -EPSILON && box.max(2) >= -EPSILON;
return box.min.z() < SINKING_Z_THRESHOLD && box.max.z() >= SINKING_Z_THRESHOLD;
}
bool GLVolume::is_below_printbed() const