Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/supermerill/SuperSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortamasmeszaros <meszaros.q@gmail.com>2018-07-27 13:28:14 +0300
committertamasmeszaros <meszaros.q@gmail.com>2018-07-27 13:28:14 +0300
commit84f97e1f64adc8b0f6f3c31fe1e22ba2e97e4572 (patch)
treea255d6b0c52f564f29776622bef01bdbd82f3ec4 /xs/src/libnest2d/tools/libnfpglue.hpp
parentc430f5718762cfa844619674dfff8cb006c09a7f (diff)
Improved libnest2d caching
Diffstat (limited to 'xs/src/libnest2d/tools/libnfpglue.hpp')
-rw-r--r--xs/src/libnest2d/tools/libnfpglue.hpp28
1 files changed, 15 insertions, 13 deletions
diff --git a/xs/src/libnest2d/tools/libnfpglue.hpp b/xs/src/libnest2d/tools/libnfpglue.hpp
index 87b0e0833..75f639445 100644
--- a/xs/src/libnest2d/tools/libnfpglue.hpp
+++ b/xs/src/libnest2d/tools/libnfpglue.hpp
@@ -5,37 +5,39 @@
namespace libnest2d {
-PolygonImpl _nfp(const PolygonImpl& sh, const PolygonImpl& cother);
+using NfpR = Nfp::NfpResult<PolygonImpl>;
+
+NfpR _nfp(const PolygonImpl& sh, const PolygonImpl& cother);
template<>
struct Nfp::NfpImpl<PolygonImpl, NfpLevel::CONVEX_ONLY> {
- PolygonImpl operator()(const PolygonImpl& sh, const PolygonImpl& cother);
+ NfpR operator()(const PolygonImpl& sh, const PolygonImpl& cother);
};
template<>
struct Nfp::NfpImpl<PolygonImpl, NfpLevel::ONE_CONVEX> {
- PolygonImpl operator()(const PolygonImpl& sh, const PolygonImpl& cother);
+ NfpR operator()(const PolygonImpl& sh, const PolygonImpl& cother);
};
template<>
struct Nfp::NfpImpl<PolygonImpl, NfpLevel::BOTH_CONCAVE> {
- PolygonImpl operator()(const PolygonImpl& sh, const PolygonImpl& cother);
+ NfpR operator()(const PolygonImpl& sh, const PolygonImpl& cother);
};
-template<>
-struct Nfp::NfpImpl<PolygonImpl, NfpLevel::ONE_CONVEX_WITH_HOLES> {
- PolygonImpl operator()(const PolygonImpl& sh, const PolygonImpl& cother);
-};
+//template<>
+//struct Nfp::NfpImpl<PolygonImpl, NfpLevel::ONE_CONVEX_WITH_HOLES> {
+// NfpResult operator()(const PolygonImpl& sh, const PolygonImpl& cother);
+//};
-template<>
-struct Nfp::NfpImpl<PolygonImpl, NfpLevel::BOTH_CONCAVE_WITH_HOLES> {
- PolygonImpl operator()(const PolygonImpl& sh, const PolygonImpl& cother);
-};
+//template<>
+//struct Nfp::NfpImpl<PolygonImpl, NfpLevel::BOTH_CONCAVE_WITH_HOLES> {
+// NfpResult operator()(const PolygonImpl& sh, const PolygonImpl& cother);
+//};
template<> struct Nfp::MaxNfpLevel<PolygonImpl> {
static const BP2D_CONSTEXPR NfpLevel value =
// NfpLevel::CONVEX_ONLY;
- NfpLevel::BOTH_CONCAVE_WITH_HOLES;
+ NfpLevel::BOTH_CONCAVE;
};
}