diff options
author | Enrico Turri <enricoturri@seznam.cz> | 2018-05-15 10:50:01 +0300 |
---|---|---|
committer | Enrico Turri <enricoturri@seznam.cz> | 2018-05-15 10:50:01 +0300 |
commit | f4303ebdb888c322e0298d4f951343e511b44062 (patch) | |
tree | d69bd5425f11b4fb1819a0e347e34d3791bd3431 /xs/src/libslic3r/BoundingBox.cpp | |
parent | 986630c2dc366bc93629e8a8ae790278ece3636f (diff) |
1st attempt of perl callback from c++ for 3DScene
Diffstat (limited to 'xs/src/libslic3r/BoundingBox.cpp')
-rw-r--r-- | xs/src/libslic3r/BoundingBox.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/xs/src/libslic3r/BoundingBox.cpp b/xs/src/libslic3r/BoundingBox.cpp index 91ba88d84..e23accbde 100644 --- a/xs/src/libslic3r/BoundingBox.cpp +++ b/xs/src/libslic3r/BoundingBox.cpp @@ -222,6 +222,16 @@ BoundingBox3Base<PointClass>::center() const } template Pointf3 BoundingBox3Base<Pointf3>::center() const; +//######################################################################################################################################33 +template <class PointClass> coordf_t +BoundingBox3Base<PointClass>::max_size() const +{ + PointClass s = size(); + return std::max(s.x, std::max(s.y, s.z)); +} +template coordf_t BoundingBox3Base<Pointf3>::max_size() const; +//######################################################################################################################################33 + // Align a coordinate to a grid. The coordinate may be negative, // the aligned value will never be bigger than the original one. static inline coord_t _align_to_grid(const coord_t coord, const coord_t spacing) { |