diff --git a/.gitmodules b/.gitmodules index ed0df4b60..614ca1471 100644 --- a/.gitmodules +++ b/.gitmodules @@ -24,3 +24,6 @@ url=https://github.com/libigl/nanogui.git [submodule "external/CoMISo"] path = external/CoMISo url = https://github.com/libigl/CoMISo.git +[submodule "external/cork"] + path = external/cork + url = https://github.com/libigl/cork.git diff --git a/include/igl/MeshBooleanType.h b/include/igl/MeshBooleanType.h new file mode 100644 index 000000000..2eb293624 --- /dev/null +++ b/include/igl/MeshBooleanType.h @@ -0,0 +1,23 @@ +// This file is part of libigl, a simple c++ geometry processing library. +// +// Copyright (C) 2015 Alec Jacobson +// +// This Source Code Form is subject to the terms of the Mozilla Public License +// v. 2.0. If a copy of the MPL was not distributed with this file, You can +// obtain one at http://mozilla.org/MPL/2.0/. +#ifndef IGL_MESH_BOOLEAN_TYPE_H +#define IGL_MESH_BOOLEAN_TYPE_H +namespace igl +{ + enum MeshBooleanType + { + MESH_BOOLEAN_TYPE_UNION = 0, + MESH_BOOLEAN_TYPE_INTERSECT = 1, + MESH_BOOLEAN_TYPE_MINUS = 2, + MESH_BOOLEAN_TYPE_XOR = 3, + MESH_BOOLEAN_TYPE_RESOLVE = 4, + NUM_MESH_BOOLEAN_TYPES = 5 + }; +}; + +#endif diff --git a/include/igl/copyleft/boolean/MeshBooleanType.h b/include/igl/copyleft/boolean/MeshBooleanType.h deleted file mode 100644 index 70828e996..000000000 --- a/include/igl/copyleft/boolean/MeshBooleanType.h +++ /dev/null @@ -1,29 +0,0 @@ -// This file is part of libigl, a simple c++ geometry processing library. -// -// Copyright (C) 2015 Alec Jacobson -// -// This Source Code Form is subject to the terms of the Mozilla Public License -// v. 2.0. If a copy of the MPL was not distributed with this file, You can -// obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_TYPE_H -#define IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_TYPE_H -namespace igl -{ - namespace copyleft - { - namespace boolean - { - enum MeshBooleanType - { - MESH_BOOLEAN_TYPE_UNION = 0, - MESH_BOOLEAN_TYPE_INTERSECT = 1, - MESH_BOOLEAN_TYPE_MINUS = 2, - MESH_BOOLEAN_TYPE_XOR = 3, - MESH_BOOLEAN_TYPE_RESOLVE = 4, - NUM_MESH_BOOLEAN_TYPES = 5 - }; - } - } -}; - -#endif diff --git a/include/igl/copyleft/boolean/BinaryWindingNumberOperations.h b/include/igl/copyleft/cgal/BinaryWindingNumberOperations.h similarity index 92% rename from include/igl/copyleft/boolean/BinaryWindingNumberOperations.h rename to include/igl/copyleft/cgal/BinaryWindingNumberOperations.h index cf7348313..87ea6f8e6 100644 --- a/include/igl/copyleft/boolean/BinaryWindingNumberOperations.h +++ b/include/igl/copyleft/cgal/BinaryWindingNumberOperations.h @@ -6,21 +6,21 @@ // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. // -#ifndef IGL_COPYLEFT_BOOLEAN_BINARY_WINDING_NUMBER_OPERATIONS_H -#define IGL_COPYLEFT_BOOLEAN_BINARY_WINDING_NUMBER_OPERATIONS_H +#ifndef IGL_COPYLEFT_CGAL_BINARY_WINDING_NUMBER_OPERATIONS_H +#define IGL_COPYLEFT_CGAL_BINARY_WINDING_NUMBER_OPERATIONS_H #include #include "../../igl_inline.h" -#include "MeshBooleanType.h" +#include "../../MeshBooleanType.h" #include namespace igl { namespace copyleft { - namespace boolean + namespace cgal { - template + template class BinaryWindingNumberOperations { public: template @@ -72,7 +72,7 @@ namespace igl }; template <> - class BinaryWindingNumberOperations { + class BinaryWindingNumberOperations { public: template typename DerivedW::Scalar operator()( diff --git a/include/igl/copyleft/boolean/CSGTree.h b/include/igl/copyleft/cgal/CSGTree.h similarity index 98% rename from include/igl/copyleft/boolean/CSGTree.h rename to include/igl/copyleft/cgal/CSGTree.h index 60fd84982..f6b328f26 100644 --- a/include/igl/copyleft/boolean/CSGTree.h +++ b/include/igl/copyleft/cgal/CSGTree.h @@ -5,11 +5,11 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_CSG_TREE_H -#define IGL_COPYLEFT_BOOLEAN_CSG_TREE_H +#ifndef IGL_COPYLEFT_CGAL_CSG_TREE_H +#define IGL_COPYLEFT_CGAL_CSG_TREE_H +#include "../../MeshBooleanType.h" #include "string_to_mesh_boolean_type.h" -#include "MeshBooleanType.h" #include "mesh_boolean.h" #include #include @@ -18,7 +18,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cgal { // Class for defining and computing a constructive solid geometry result // out of a tree of boolean operations on "solid" triangle meshes. diff --git a/include/igl/copyleft/boolean/mesh_boolean.cpp b/include/igl/copyleft/cgal/mesh_boolean.cpp similarity index 74% rename from include/igl/copyleft/boolean/mesh_boolean.cpp rename to include/igl/copyleft/cgal/mesh_boolean.cpp index 48fb2872d..719017f31 100644 --- a/include/igl/copyleft/boolean/mesh_boolean.cpp +++ b/include/igl/copyleft/cgal/mesh_boolean.cpp @@ -9,11 +9,11 @@ // #include "mesh_boolean.h" #include "BinaryWindingNumberOperations.h" -#include "../cgal/assign_scalar.h" -#include "../cgal/propagate_winding_numbers.h" -#include "../cgal/remesh_self_intersections.h" -#include "../cgal/relabel_small_immersed_cells.h" -#include "../cgal/extract_cells.h" +#include "assign_scalar.h" +#include "propagate_winding_numbers.h" +#include "remesh_self_intersections.h" +#include "relabel_small_immersed_cells.h" +#include "extract_cells.h" #include "../../extract_manifold_patches.h" #include "../../remove_unreferenced.h" #include "../../unique_simplices.h" @@ -40,7 +40,7 @@ template < typename DerivedVC, typename DerivedFC, typename DerivedJ> -IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( +IGL_INLINE bool igl::copyleft::cgal::mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -265,7 +265,7 @@ template < typename DerivedVC, typename DerivedFC, typename DerivedJ> -IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( +IGL_INLINE bool igl::copyleft::cgal::mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -279,26 +279,26 @@ IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( switch (type) { case MESH_BOOLEAN_TYPE_UNION: - return igl::copyleft::boolean::mesh_boolean( - VA, FA, VB, FB, igl::copyleft::boolean::BinaryUnion(), - igl::copyleft::boolean::KeepInside(), resolve_func, VC, FC, J); + return igl::copyleft::cgal::mesh_boolean( + VA, FA, VB, FB, igl::copyleft::cgal::BinaryUnion(), + igl::copyleft::cgal::KeepInside(), resolve_func, VC, FC, J); case MESH_BOOLEAN_TYPE_INTERSECT: - return igl::copyleft::boolean::mesh_boolean( - VA, FA, VB, FB, igl::copyleft::boolean::BinaryIntersect(), - igl::copyleft::boolean::KeepInside(), resolve_func, VC, FC, J); + return igl::copyleft::cgal::mesh_boolean( + VA, FA, VB, FB, igl::copyleft::cgal::BinaryIntersect(), + igl::copyleft::cgal::KeepInside(), resolve_func, VC, FC, J); case MESH_BOOLEAN_TYPE_MINUS: - return igl::copyleft::boolean::mesh_boolean( - VA, FA, VB, FB, igl::copyleft::boolean::BinaryMinus(), - igl::copyleft::boolean::KeepInside(), resolve_func, VC, FC, J); + return igl::copyleft::cgal::mesh_boolean( + VA, FA, VB, FB, igl::copyleft::cgal::BinaryMinus(), + igl::copyleft::cgal::KeepInside(), resolve_func, VC, FC, J); case MESH_BOOLEAN_TYPE_XOR: - return igl::copyleft::boolean::mesh_boolean( - VA, FA, VB, FB, igl::copyleft::boolean::BinaryXor(), - igl::copyleft::boolean::KeepInside(), resolve_func, VC, FC, J); + return igl::copyleft::cgal::mesh_boolean( + VA, FA, VB, FB, igl::copyleft::cgal::BinaryXor(), + igl::copyleft::cgal::KeepInside(), resolve_func, VC, FC, J); case MESH_BOOLEAN_TYPE_RESOLVE: //op = binary_resolve(); - return igl::copyleft::boolean::mesh_boolean( - VA, FA, VB, FB, igl::copyleft::boolean::BinaryResolve(), - igl::copyleft::boolean::KeepAll(), resolve_func, VC, FC, J); + return igl::copyleft::cgal::mesh_boolean( + VA, FA, VB, FB, igl::copyleft::cgal::BinaryResolve(), + igl::copyleft::cgal::KeepAll(), resolve_func, VC, FC, J); default: assert(false && "Unsupported boolean type."); return false; @@ -313,7 +313,7 @@ template < typename DerivedVC, typename DerivedFC, typename DerivedJ> -IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( +IGL_INLINE bool igl::copyleft::cgal::mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -371,7 +371,7 @@ template < typename DerivedFB, typename DerivedVC, typename DerivedFC> -IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( +IGL_INLINE bool igl::copyleft::cgal::mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -381,14 +381,14 @@ IGL_INLINE bool igl::copyleft::boolean::mesh_boolean( Eigen::PlainObjectBase & FC) { Eigen::Matrix J; - return igl::copyleft::boolean::mesh_boolean(VA,FA,VB,FB,type,VC,FC,J); + return igl::copyleft::cgal::mesh_boolean(VA,FA,VB,FB,type,VC,FC,J); } #ifdef IGL_STATIC_LIBRARY // Explicit template specialization -template bool igl::copyleft::boolean::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::copyleft::boolean::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); -template bool igl::copyleft::boolean::mesh_boolean, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase > const&, igl::copyleft::boolean::MeshBooleanType const&, Eigen::PlainObjectBase, -1, 3, 0, -1, 3> >&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); -template bool igl::copyleft::boolean::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::copyleft::boolean::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template bool igl::copyleft::cgal::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template bool igl::copyleft::cgal::mesh_boolean, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase > const&, igl::MeshBooleanType const&, Eigen::PlainObjectBase, -1, 3, 0, -1, 3> >&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template bool igl::copyleft::cgal::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); #undef IGL_STATIC_LIBRARY #include "../../remove_unreferenced.cpp" template void igl::remove_unreferenced, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix, -1, 3, 0, -1, 3>, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase, -1, 3, 0, -1, 3> >&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); diff --git a/include/igl/copyleft/boolean/mesh_boolean.h b/include/igl/copyleft/cgal/mesh_boolean.h similarity index 98% rename from include/igl/copyleft/boolean/mesh_boolean.h rename to include/igl/copyleft/cgal/mesh_boolean.h index f56c06388..432474509 100644 --- a/include/igl/copyleft/boolean/mesh_boolean.h +++ b/include/igl/copyleft/cgal/mesh_boolean.h @@ -7,11 +7,11 @@ // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. // -#ifndef IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_H -#define IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_H +#ifndef IGL_COPYLEFT_CGAL_MESH_BOOLEAN_H +#define IGL_COPYLEFT_CGAL_MESH_BOOLEAN_H #include "../../igl_inline.h" -#include "MeshBooleanType.h" +#include "../../MeshBooleanType.h" #include #include @@ -19,7 +19,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cgal { // MESH_BOOLEAN Compute boolean csg operations on "solid", consistently // oriented meshes. diff --git a/include/igl/copyleft/boolean/minkowski_sum.cpp b/include/igl/copyleft/cgal/minkowski_sum.cpp similarity index 98% rename from include/igl/copyleft/boolean/minkowski_sum.cpp rename to include/igl/copyleft/cgal/minkowski_sum.cpp index 6a9fa9919..d7a6ee8f3 100644 --- a/include/igl/copyleft/boolean/minkowski_sum.cpp +++ b/include/igl/copyleft/cgal/minkowski_sum.cpp @@ -12,7 +12,7 @@ #include "../../unique.h" #include "../../get_seconds.h" #include "../../edges.h" -#include "../cgal/assign_scalar.h" +#include "assign_scalar.h" #include #include #include @@ -24,7 +24,7 @@ template < typename DerivedW, typename DerivedG, typename DerivedJ> -IGL_INLINE void igl::copyleft::boolean::minkowski_sum( +IGL_INLINE void igl::copyleft::cgal::minkowski_sum( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -149,7 +149,7 @@ template < typename DerivedW, typename DerivedG, typename DerivedJ> -IGL_INLINE void igl::copyleft::boolean::minkowski_sum( +IGL_INLINE void igl::copyleft::cgal::minkowski_sum( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::Matrix & s, @@ -354,7 +354,7 @@ template < typename DerivedW, typename DerivedG, typename DerivedJ> -IGL_INLINE void igl::copyleft::boolean::minkowski_sum( +IGL_INLINE void igl::copyleft::cgal::minkowski_sum( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::Matrix & s, diff --git a/include/igl/copyleft/boolean/minkowski_sum.h b/include/igl/copyleft/cgal/minkowski_sum.h similarity index 99% rename from include/igl/copyleft/boolean/minkowski_sum.h rename to include/igl/copyleft/cgal/minkowski_sum.h index 3991aa6ac..f1b57c30c 100644 --- a/include/igl/copyleft/boolean/minkowski_sum.h +++ b/include/igl/copyleft/cgal/minkowski_sum.h @@ -15,7 +15,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cgal { // Compute the Minkowski sum of a closed triangle mesh (V,F) and a // set of simplices in 3D. diff --git a/include/igl/copyleft/cgal/points_inside_component.h b/include/igl/copyleft/cgal/points_inside_component.h index c87ee3be4..f21354455 100644 --- a/include/igl/copyleft/cgal/points_inside_component.h +++ b/include/igl/copyleft/cgal/points_inside_component.h @@ -12,7 +12,8 @@ #include #include -namespace igl { +namespace igl +{ namespace copyleft { namespace cgal { diff --git a/include/igl/copyleft/boolean/string_to_mesh_boolean_type.cpp b/include/igl/copyleft/cgal/string_to_mesh_boolean_type.cpp similarity index 81% rename from include/igl/copyleft/boolean/string_to_mesh_boolean_type.cpp rename to include/igl/copyleft/cgal/string_to_mesh_boolean_type.cpp index 1dbec9fa5..acfa1f292 100644 --- a/include/igl/copyleft/boolean/string_to_mesh_boolean_type.cpp +++ b/include/igl/copyleft/cgal/string_to_mesh_boolean_type.cpp @@ -3,7 +3,7 @@ #include #include -IGL_INLINE bool igl::copyleft::boolean::string_to_mesh_boolean_type( +IGL_INLINE bool igl::copyleft::cgal::string_to_mesh_boolean_type( const std::string & s, MeshBooleanType & type) { @@ -22,7 +22,8 @@ IGL_INLINE bool igl::copyleft::boolean::string_to_mesh_boolean_type( { type = MESH_BOOLEAN_TYPE_INTERSECT; }else if( - find_any({"minus","subtract","difference","relative complement","m","\\"},eff_s)) + find_any( + {"minus","subtract","difference","relative complement","m","\\"},eff_s)) { type = MESH_BOOLEAN_TYPE_MINUS; }else if(find_any({"xor","symmetric difference","x","∆"},eff_s)) @@ -38,7 +39,8 @@ IGL_INLINE bool igl::copyleft::boolean::string_to_mesh_boolean_type( return true; } -IGL_INLINE igl::copyleft::boolean::MeshBooleanType igl::copyleft::boolean::string_to_mesh_boolean_type( +IGL_INLINE igl::MeshBooleanType +igl::copyleft::cgal::string_to_mesh_boolean_type( const std::string & s) { MeshBooleanType type; diff --git a/include/igl/copyleft/boolean/string_to_mesh_boolean_type.h b/include/igl/copyleft/cgal/string_to_mesh_boolean_type.h similarity index 87% rename from include/igl/copyleft/boolean/string_to_mesh_boolean_type.h rename to include/igl/copyleft/cgal/string_to_mesh_boolean_type.h index 64ac324d3..4781099f1 100644 --- a/include/igl/copyleft/boolean/string_to_mesh_boolean_type.h +++ b/include/igl/copyleft/cgal/string_to_mesh_boolean_type.h @@ -5,18 +5,18 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_STRING_TO_MESH_BOOLEAN_H -#define IGL_COPYLEFT_BOOLEAN_STRING_TO_MESH_BOOLEAN_H +#ifndef IGL_COPYLEFT_CGAL_STRING_TO_MESH_BOOLEAN_H +#define IGL_COPYLEFT_CGAL_STRING_TO_MESH_BOOLEAN_H #include "../../igl_inline.h" -#include "MeshBooleanType.h" +#include "../../MeshBooleanType.h" #include namespace igl { namespace copyleft { - namespace boolean + namespace cgal { // Convert string to boolean type // diff --git a/include/igl/copyleft/boolean/from_cork_mesh.cpp b/include/igl/copyleft/cork/from_cork_mesh.cpp similarity index 59% rename from include/igl/copyleft/boolean/from_cork_mesh.cpp rename to include/igl/copyleft/cork/from_cork_mesh.cpp index c3a392607..4c81d318a 100644 --- a/include/igl/copyleft/boolean/from_cork_mesh.cpp +++ b/include/igl/copyleft/cork/from_cork_mesh.cpp @@ -5,13 +5,12 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_NO_CORK #include "from_cork_mesh.h" template < typename DerivedV, typename DerivedF> -IGL_INLINE void igl::copyleft::boolean::from_cork_mesh( +IGL_INLINE void igl::copyleft::cork::from_cork_mesh( const CorkTriMesh & mesh, Eigen::PlainObjectBase & V, Eigen::PlainObjectBase & F) @@ -37,8 +36,6 @@ IGL_INLINE void igl::copyleft::boolean::from_cork_mesh( #ifdef IGL_STATIC_LIBRARY // Explicit template specialization -template void igl::copyleft::boolean::from_cork_mesh, Eigen::Matrix >(CorkTriMesh const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); -template void igl::copyleft::boolean::from_cork_mesh, Eigen::Matrix >(CorkTriMesh const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); -#endif - +template void igl::copyleft::cork::from_cork_mesh, Eigen::Matrix >(CorkTriMesh const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template void igl::copyleft::cork::from_cork_mesh, Eigen::Matrix >(CorkTriMesh const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); #endif diff --git a/include/igl/copyleft/boolean/from_cork_mesh.h b/include/igl/copyleft/cork/from_cork_mesh.h similarity index 88% rename from include/igl/copyleft/boolean/from_cork_mesh.h rename to include/igl/copyleft/cork/from_cork_mesh.h index 6bb632b32..a2fef28c1 100644 --- a/include/igl/copyleft/boolean/from_cork_mesh.h +++ b/include/igl/copyleft/cork/from_cork_mesh.h @@ -5,9 +5,8 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_FROM_CORK_MESH_H -#define IGL_COPYLEFT_BOOLEAN_FROM_CORK_MESH_H -#ifndef IGL_NO_CORK +#ifndef IGL_COPYLEFT_CORK_FROM_CORK_MESH_H +#define IGL_COPYLEFT_CORK_FROM_CORK_MESH_H #include "../../igl_inline.h" #include #include @@ -15,7 +14,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cork { // Convert cork's triangle mesh representation to a (V,F) mesh. // @@ -38,4 +37,3 @@ namespace igl # include "from_cork_mesh.cpp" #endif #endif -#endif diff --git a/include/igl/copyleft/boolean/mesh_boolean_cork.cpp b/include/igl/copyleft/cork/mesh_boolean.cpp similarity index 59% rename from include/igl/copyleft/boolean/mesh_boolean_cork.cpp rename to include/igl/copyleft/cork/mesh_boolean.cpp index c6d5c3381..f826d3555 100644 --- a/include/igl/copyleft/boolean/mesh_boolean_cork.cpp +++ b/include/igl/copyleft/cork/mesh_boolean.cpp @@ -5,8 +5,7 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_NO_CORK -#include "mesh_boolean_cork.h" +#include "mesh_boolean.h" #include "to_cork_mesh.h" #include "from_cork_mesh.h" @@ -17,7 +16,7 @@ template < typename DerivedFB, typename DerivedVC, typename DerivedFC> -IGL_INLINE void igl::copyleft::boolean::mesh_boolean_cork( +IGL_INLINE void igl::copyleft::cork::mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -94,8 +93,7 @@ IGL_INLINE void igl::copyleft::boolean::mesh_boolean_cork( } #ifdef IGL_STATIC_LIBRARY // Explicit template specialization -template void igl::copyleft::boolean::mesh_boolean_cork, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); -template void igl::copyleft::boolean::mesh_boolean_cork, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::copyleft::boolean::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template void igl::copyleft::cork::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); +template void igl::copyleft::cork::mesh_boolean, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, igl::MeshBooleanType const&, Eigen::PlainObjectBase >&, Eigen::PlainObjectBase >&); #endif -#endif diff --git a/include/igl/copyleft/boolean/mesh_boolean_cork.h b/include/igl/copyleft/cork/mesh_boolean.h similarity index 86% rename from include/igl/copyleft/boolean/mesh_boolean_cork.h rename to include/igl/copyleft/cork/mesh_boolean.h index 5e16f9666..db2589284 100644 --- a/include/igl/copyleft/boolean/mesh_boolean_cork.h +++ b/include/igl/copyleft/cork/mesh_boolean.h @@ -5,10 +5,9 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_CORK_H -#define IGL_COPYLEFT_BOOLEAN_MESH_BOOLEAN_CORK_H -#ifndef IGL_NO_CORK -#include "MeshBooleanType.h" +#ifndef IGL_COPYLEFT_CORK_MESH_BOOLEAN_H +#define IGL_COPYLEFT_CORK_MESH_BOOLEAN_H +#include "../../MeshBooleanType.h" #include "../../igl_inline.h" #include #include // for consistent uint @@ -17,7 +16,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cork { // Compute a boolean operation on two input meshes using the cork library. // @@ -37,7 +36,7 @@ namespace igl typename DerivedFB, typename DerivedVC, typename DerivedFC> - IGL_INLINE void mesh_boolean_cork( + IGL_INLINE void mesh_boolean( const Eigen::PlainObjectBase & VA, const Eigen::PlainObjectBase & FA, const Eigen::PlainObjectBase & VB, @@ -50,8 +49,7 @@ namespace igl } #ifndef IGL_STATIC_LIBRARY -# include "mesh_boolean_cork.cpp" -#endif +# include "mesh_boolean.cpp" #endif #endif diff --git a/include/igl/copyleft/boolean/to_cork_mesh.cpp b/include/igl/copyleft/cork/to_cork_mesh.cpp similarity index 62% rename from include/igl/copyleft/boolean/to_cork_mesh.cpp rename to include/igl/copyleft/cork/to_cork_mesh.cpp index a332d8092..96537ada9 100644 --- a/include/igl/copyleft/boolean/to_cork_mesh.cpp +++ b/include/igl/copyleft/cork/to_cork_mesh.cpp @@ -5,12 +5,11 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_NO_CORK #include "to_cork_mesh.h" template < typename DerivedV, typename DerivedF> -IGL_INLINE void igl::copyleft::boolean::to_cork_mesh( +IGL_INLINE void igl::copyleft::cork::to_cork_mesh( const Eigen::PlainObjectBase & V, const Eigen::PlainObjectBase & F, CorkTriMesh & mesh) @@ -20,7 +19,7 @@ IGL_INLINE void igl::copyleft::boolean::to_cork_mesh( assert((V.cols() == 0 || V.cols() == 3) && "Vertices should be in 3D."); mesh.n_triangles = F.rows(); mesh.n_vertices = V.rows(); - mesh.vertices = new double[mesh.n_vertices*3]; + mesh.vertices = new float[mesh.n_vertices*3]; mesh.triangles = new uint[mesh.n_triangles*3]; for(size_t v = 0;v, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, CorkTriMesh&); -template void igl::copyleft::boolean::to_cork_mesh, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, CorkTriMesh&); -#endif +template void igl::copyleft::cork::to_cork_mesh, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, CorkTriMesh&); +template void igl::copyleft::cork::to_cork_mesh, Eigen::Matrix >(Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, CorkTriMesh&); #endif diff --git a/include/igl/copyleft/boolean/to_cork_mesh.h b/include/igl/copyleft/cork/to_cork_mesh.h similarity index 88% rename from include/igl/copyleft/boolean/to_cork_mesh.h rename to include/igl/copyleft/cork/to_cork_mesh.h index 60ae184b5..b034e357f 100644 --- a/include/igl/copyleft/boolean/to_cork_mesh.h +++ b/include/igl/copyleft/cork/to_cork_mesh.h @@ -5,9 +5,8 @@ // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. -#ifndef IGL_COPYLEFT_BOOLEAN_TO_CORK_MESH_H -#define IGL_COPYLEFT_BOOLEAN_TO_CORK_MESH_H -#ifndef IGL_NO_CORK +#ifndef IGL_COPYLEFT_CORK_TO_CORK_MESH_H +#define IGL_COPYLEFT_CORK_TO_CORK_MESH_H #include "../../igl_inline.h" #include #include @@ -15,7 +14,7 @@ namespace igl { namespace copyleft { - namespace boolean + namespace cork { // Convert a (V,F) mesh to a cork's triangle mesh representation. // @@ -38,4 +37,3 @@ namespace igl # include "to_cork_mesh.cpp" #endif #endif -#endif diff --git a/optional/CMakeLists.txt b/optional/CMakeLists.txt index 8ce98ff80..65669fbed 100644 --- a/optional/CMakeLists.txt +++ b/optional/CMakeLists.txt @@ -17,17 +17,21 @@ endif() option(LIBIGL_USE_STATIC_LIBRARY "Use LibIGL as static library" ON) -option(LIBIGL_WITH_ANTTWEAKBAR "Use AntTweakBar" OFF) +option(LIBIGL_WITH_ANTTWEAKBAR "Use AntTweakBar" ON) option(LIBIGL_WITH_BBW "Use BBW" ON) -option(LIBIGL_WITH_BOOLEAN "Use Cork boolean" OFF) -option(LIBIGL_WITH_CGAL "Use CGAL" OFF) +find_package(CGAL QUIET) +option(LIBIGL_WITH_CGAL "Use CGAL" "${CGAL_FOUND}") option(LIBIGL_WITH_COMISO "Use CoMiso" ON) +option(LIBIGL_WITH_CORK "Use Cork" ON) option(LIBIGL_WITH_EMBREE "Use Embree" ON) option(LIBIGL_WITH_LIM "Use LIM" ON) -option(LIBIGL_WITH_MATLAB "Use Matlab" OFF) -option(LIBIGL_WITH_MOSEK "Use MOSEK" OFF) +find_package(MATLAB QUIET) +option(LIBIGL_WITH_MATLAB "Use Matlab" "${MATLAB_FOUND}") +find_package(MOSEK QUIET) +option(LIBIGL_WITH_MOSEK "Use MOSEK" "${MOSEK_FOUND}") option(LIBIGL_WITH_NANOGUI "Use Nanogui menu" OFF) -option(LIBIGL_WITH_OPENGL_AND_PNG "Use OpenGL" ON) +option(LIBIGL_WITH_OPENGL "Use OpenGL" ON) +option(LIBIGL_WITH_PNG "Use PNG" ON) option(LIBIGL_WITH_TETGEN "Use Tetgen" ON) option(LIBIGL_WITH_TRIANGLE "Use Triangle" ON) option(LIBIGL_WITH_VIEWER "Use OpenGL viewer" ON) diff --git a/shared/cmake/CMakeLists.txt b/shared/cmake/CMakeLists.txt index f93dce277..721426525 100644 --- a/shared/cmake/CMakeLists.txt +++ b/shared/cmake/CMakeLists.txt @@ -2,10 +2,10 @@ cmake_minimum_required(VERSION 2.8.12) project(libigl) ### Available options ### -option(LIBIGL_USE_STATIC_LIBRARY "Use libIGL as static library" OFF) +option(LIBIGL_USE_STATIC_LIBRARY "Use libigl as static library" OFF) option(LIBIGL_WITH_ANTTWEAKBAR "Use AntTweakBar" OFF) option(LIBIGL_WITH_BBW "Use BBW" OFF) -option(LIBIGL_WITH_BOOLEAN "Use Cork boolean" OFF) +option(LIBIGL_WITH_CORK "Use Cork" OFF) option(LIBIGL_WITH_CGAL "Use CGAL" OFF) option(LIBIGL_WITH_COMISO "Use CoMiso" OFF) option(LIBIGL_WITH_EMBREE "Use Embree" OFF) @@ -13,7 +13,8 @@ option(LIBIGL_WITH_LIM "Use LIM" OFF) option(LIBIGL_WITH_MATLAB "Use Matlab" OFF) option(LIBIGL_WITH_MOSEK "Use MOSEK" OFF) option(LIBIGL_WITH_NANOGUI "Use Nanogui menu" OFF) -option(LIBIGL_WITH_OPENGL_AND_PNG "Use OpenGL" OFF) +option(LIBIGL_WITH_OPENGL "Use OpenGL" OFF) +option(LIBIGL_WITH_PNG "Use PNG" OFF) option(LIBIGL_WITH_TETGEN "Use Tetgen" OFF) option(LIBIGL_WITH_TRIANGLE "Use Triangle" OFF) option(LIBIGL_WITH_VIEWER "Use OpenGL viewer" OFF) @@ -116,6 +117,42 @@ if(LIBIGL_WITH_BBW) endif() endif() +### Compile the cgal parts ### +if(LIBIGL_WITH_CGAL) # to be cleaned + find_package(CGAL REQUIRED) + # set(Boost_USE_MULTITHREADED ON) + # set(Boost_USE_STATIC_LIBS ON) + # + # find_package(BOOST REQUIRED) + include(${CGAL_USE_FILE}) + list(APPEND LIBIGL_INCLUDE_DIRS ${CGAL_3RD_PARTY_INCLUDE_DIRS}) + list(APPEND LIBIGL_INCLUDE_DIRS ${CGAL_INCLUDE_DIRS}) + list(APPEND LIBIGL_EXTRA_LIBRARIES ${CGAL_3RD_PARTY_LIBRARIES}) + list(APPEND LIBIGL_EXTRA_LIBRARIES ${CGAL_LIBRARIES}) + if(LIBIGL_USE_STATIC_LIBRARY) + CompileIGL_Module_Copyleft("cgal") + target_include_directories(iglcgal PRIVATE + ${CGAL_3RD_PARTY_INCLUDE_DIRS} + ${CGAL_INCLUDE_DIRS}) + endif() +endif() + +### Compile the cork parts ### +if(LIBIGL_WITH_CORK) + set(CORK_DIR "${LIBIGL_EXTERNAL}/cork") + set(CORK_INCLUDE_DIR "${CORK_DIR}/src") + # call this "lib-cork" instead of "cork", otherwise cmake gets confused about + # "cork" executable + add_subdirectory("${CORK_DIR}" "lib-cork") + list(APPEND LIBIGL_INCLUDE_DIRS "${CORK_INCLUDE_DIR}") + list(APPEND LIBIGL_EXTRA_LIBRARIES "cork") + if(LIBIGL_USE_STATIC_LIBRARY) + CompileIGL_Module_Copyleft("cork") + target_include_directories(iglcork PRIVATE + ${CORK_INCLUDE_DIR}) + endif() +endif() + ### Compile the embree part ### if(LIBIGL_WITH_EMBREE) set(EMBREE_DIR "${LIBIGL_EXTERNAL}/embree") @@ -255,21 +292,28 @@ if(LIBIGL_WITH_VIEWER) endif() endif() -### Compile the opengl and png parts ### -if(LIBIGL_WITH_OPENGL_AND_PNG) +### Compile the opengl parts ### +if(LIBIGL_WITH_OPENGL) + if(LIBIGL_USE_STATIC_LIBRARY) + CompileIGL_Module("opengl") + CompileIGL_Module("opengl2") + if(NOT APPLE) + target_include_directories(iglopengl PRIVATE "${LIBIGL_EXTERNAL}/nanogui/ext/glew/include") + target_include_directories(iglopengl2 PRIVATE "${LIBIGL_EXTERNAL}/nanogui/ext/glew/include") + endif() + endif() +endif() + +### Compile the png parts ### +if(LIBIGL_WITH_PNG) set(STB_IMAGE_DIR "${LIBIGL_EXTERNAL}/stb_image") add_subdirectory("${STB_IMAGE_DIR}" "stb_image") list(APPEND LIBIGL_INCLUDE_DIRS ${STB_IMAGE_DIR}) list(APPEND LIBIGL_EXTRA_LIBRARIES "stb_image") - if(LIBIGL_USE_STATIC_LIBRARY) - CompileIGL_Module("opengl") - CompileIGL_Module("opengl2") CompileIGL_Module("png") target_include_directories(iglpng PRIVATE ${STB_IMAGE_DIR}) if(NOT APPLE) - target_include_directories(iglopengl PRIVATE "${LIBIGL_EXTERNAL}/nanogui/ext/glew/include") - target_include_directories(iglopengl2 PRIVATE "${LIBIGL_EXTERNAL}/nanogui/ext/glew/include") target_include_directories(iglpng PRIVATE "${LIBIGL_EXTERNAL}/nanogui/ext/glew/include") endif() endif() @@ -333,7 +377,6 @@ endif() ### Compile the xml part ### if(LIBIGL_WITH_XML) set(TINYXML2_DIR "${LIBIGL_EXTERNAL}/tinyxml2") - add_library(tinyxml2 STATIC ${TINYXML2_DIR}/tinyxml2.cpp ${TINYXML2_DIR}/tinyxml2.h) set_target_properties(tinyxml2 PROPERTIES COMPILE_DEFINITIONS "TINYXML2_EXPORT" @@ -341,62 +384,12 @@ if(LIBIGL_WITH_XML) SOVERSION "3") list(APPEND LIBIGL_INCLUDE_DIRS ${TINYXML2_DIR}) list(APPEND LIBIGL_EXTRA_LIBRARIES "tinyxml2") - if(LIBIGL_USE_STATIC_LIBRARY) CompileIGL_Module("xml") target_include_directories(iglxml PRIVATE ${TINYXML2_DIR}) endif() endif() -### Compile the boolean and cgal parts ### -if(LIBIGL_WITH_CGAL) # to be cleaned - find_package(CGAL REQUIRED) - # set(Boost_USE_MULTITHREADED ON) - # set(Boost_USE_STATIC_LIBS ON) - # - # find_package(BOOST REQUIRED) - - include(${CGAL_USE_FILE}) - - list(APPEND LIBIGL_INCLUDE_DIRS ${CGAL_3RD_PARTY_INCLUDE_DIRS}) - list(APPEND LIBIGL_INCLUDE_DIRS ${CGAL_INCLUDE_DIRS}) - list(APPEND LIBIGL_EXTRA_LIBRARIES ${CGAL_3RD_PARTY_LIBRARIES}) - list(APPEND LIBIGL_EXTRA_LIBRARIES ${CGAL_LIBRARIES}) - - if(LIBIGL_USE_STATIC_LIBRARY) - CompileIGL_Module_Copyleft("cgal") - target_include_directories(iglcgal PRIVATE - ${CGAL_3RD_PARTY_INCLUDE_DIRS} - ${CGAL_INCLUDE_DIRS}) - endif() - - if(LIBIGL_WITH_BOOLEAN) - find_package(CORK QUIET) - if(CORK_FOUND) - list(APPEND LIBIGL_INCLUDE_DIRS ${CORK_INCLUDE_DIR}) - list(APPEND LIBIGL_EXTRA_LIBRARIES ${CORK_LIBRARIES}) - - if(LIBIGL_USE_STATIC_LIBRARY) - CompileIGL_Module_Copyleft("boolean") - target_include_directories(iglboolean PRIVATE - ${CGAL_3RD_PARTY_INCLUDE_DIRS} - ${CGAL_INCLUDE_DIRS} - ${CORK_INCLUDE_DIR}) - endif() - else() - list(APPEND LIBIGL_DEFINITIONS "-DIGL_NO_CORK") - - if(LIBIGL_USE_STATIC_LIBRARY) - CompileIGL_Module_Copyleft("boolean") - target_include_directories(iglboolean PRIVATE - ${CGAL_3RD_PARTY_INCLUDE_DIRS} - ${CGAL_INCLUDE_DIRS}) - target_compile_definitions(iglboolean PRIVATE -DIGL_NO_CORK) - endif() - endif() - endif() -endif() - # Function to print list nicely function(print_list title list) message("-- ${title}:") @@ -415,8 +408,8 @@ if(NOT ${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME}) set(LIBIGL_DEFINITIONS ${LIBIGL_DEFINITIONS} PARENT_SCOPE) ### ligIGL information ### - print_list("libIGL includes" "${LIBIGL_INCLUDE_DIRS}") - print_list("libIGL libraries" "${LIBIGL_LIBRARIES}") - print_list("libIGL extra libraries" "${LIBIGL_EXTRA_LIBRARIES}") - print_list("libIGL definitions" "${LIBIGL_DEFINITIONS}") + print_list("libigl includes" "${LIBIGL_INCLUDE_DIRS}") + print_list("libigl libraries" "${LIBIGL_LIBRARIES}") + print_list("libigl extra libraries" "${LIBIGL_EXTRA_LIBRARIES}") + print_list("libigl definitions" "${LIBIGL_DEFINITIONS}") endif() diff --git a/tutorial/609_Boolean/main.cpp b/tutorial/609_Boolean/main.cpp index 66d68fc6a..38dfa36cf 100755 --- a/tutorial/609_Boolean/main.cpp +++ b/tutorial/609_Boolean/main.cpp @@ -1,7 +1,7 @@ #include //#define IGL_NO_CORK //#undef IGL_STATIC_LIBRARY -#include +#include #include #include @@ -12,8 +12,8 @@ Eigen::MatrixXd VA,VB,VC; Eigen::VectorXi J,I; Eigen::MatrixXi FA,FB,FC; -igl::copyleft::boolean::MeshBooleanType boolean_type( - igl::copyleft::boolean::MESH_BOOLEAN_TYPE_UNION); +igl::MeshBooleanType boolean_type( + igl::MESH_BOOLEAN_TYPE_UNION); const char * MESH_BOOLEAN_TYPE_NAMES[] = { @@ -26,7 +26,7 @@ const char * MESH_BOOLEAN_TYPE_NAMES[] = void update(igl::viewer::Viewer &viewer) { - igl::copyleft::boolean::mesh_boolean(VA,FA,VB,FB,boolean_type,VC,FC,J); + igl::copyleft::cgal::mesh_boolean(VA,FA,VB,FB,boolean_type,VC,FC,J); Eigen::MatrixXd C(FC.rows(),3); for(size_t f = 0;f( - (boolean_type+1)% igl::copyleft::boolean::NUM_MESH_BOOLEAN_TYPES); + static_cast( + (boolean_type+1)% igl::NUM_MESH_BOOLEAN_TYPES); break; case ',': boolean_type = - static_cast( - (boolean_type+igl::copyleft::boolean::NUM_MESH_BOOLEAN_TYPES-1)% - igl::copyleft::boolean::NUM_MESH_BOOLEAN_TYPES); + static_cast( + (boolean_type+igl::NUM_MESH_BOOLEAN_TYPES-1)% + igl::NUM_MESH_BOOLEAN_TYPES); break; case '[': viewer.core.camera_dnear -= 0.1; @@ -68,7 +68,7 @@ bool key_down(igl::viewer::Viewer &viewer, unsigned char key, int mods) return true; } std::cout<<"A "< -#include +#include #include #include #include @@ -9,7 +9,7 @@ int main(int argc, char * argv[]) { using namespace Eigen; - using namespace igl::copyleft::boolean; + using namespace igl::copyleft::cgal; using namespace std; using namespace igl; cout<