Tech ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION merged into tech ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS

This commit is contained in:
enricoturri1966 2021-10-01 13:13:26 +02:00
parent efb08cf55a
commit f84838028b
6 changed files with 18 additions and 32 deletions

View file

@ -278,10 +278,10 @@ private:
std::shared_ptr<const TriangleMesh> m_convex_hull;
// Bounding box of this volume, in unscaled coordinates.
std::optional<BoundingBoxf3> m_transformed_convex_hull_bounding_box;
#if ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#if ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
// Bounding box of the non sinking part of this volume, in unscaled coordinates.
std::optional<BoundingBoxf3> m_transformed_non_sinking_bounding_box;
#endif // ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#endif // ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
class SinkingContours
{
@ -472,12 +472,12 @@ public:
BoundingBoxf3 transformed_convex_hull_bounding_box(const Transform3d &trafo) const;
// caching variant
const BoundingBoxf3& transformed_convex_hull_bounding_box() const;
#if ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#if ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
// non-caching variant
BoundingBoxf3 transformed_non_sinking_bounding_box(const Transform3d& trafo) const;
// caching variant
const BoundingBoxf3& transformed_non_sinking_bounding_box() const;
#endif // ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#endif // ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
// convex hull
const TriangleMesh* convex_hull() const { return m_convex_hull.get(); }
@ -490,7 +490,7 @@ public:
void finalize_geometry(bool opengl_initialized) { this->indexed_vertex_array.finalize_geometry(opengl_initialized); }
void release_geometry() { this->indexed_vertex_array.release_geometry(); }
#if ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#if ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
void set_bounding_boxes_as_dirty() {
m_transformed_bounding_box.reset();
m_transformed_convex_hull_bounding_box.reset();
@ -498,7 +498,7 @@ public:
}
#else
void set_bounding_boxes_as_dirty() { m_transformed_bounding_box.reset(); m_transformed_convex_hull_bounding_box.reset(); }
#endif // ENABLE_FIX_SINKING_OBJECT_OUT_OF_BED_DETECTION
#endif // ENABLE_OUT_OF_BED_DETECTION_IMPROVEMENTS
bool is_sla_support() const;
bool is_sla_pad() const;