From dfc877cd2ac42e978fe0afffce739d48ce4be52d Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Mon, 2 Jan 2017 17:08:12 +0100 Subject: [PATCH] CatmullClark now works with borders too --- .../examples/Subdivision_method_3/CMakeLists.txt | 1 - .../examples/Subdivision_method_3/CatmullClark_subdivision.cpp | 2 ++ Subdivision_method_3/include/CGAL/Subdivision_mask_3.h | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Subdivision_method_3/examples/Subdivision_method_3/CMakeLists.txt b/Subdivision_method_3/examples/Subdivision_method_3/CMakeLists.txt index f43d490cc30..c37dc4524c4 100644 --- a/Subdivision_method_3/examples/Subdivision_method_3/CMakeLists.txt +++ b/Subdivision_method_3/examples/Subdivision_method_3/CMakeLists.txt @@ -14,7 +14,6 @@ if ( CGAL_FOUND ) include( CGAL_CreateSingleSourceCGALProgram ) - include_directories (BEFORE "../../include") # create a target per cppfile file(GLOB cppfiles RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp) diff --git a/Subdivision_method_3/examples/Subdivision_method_3/CatmullClark_subdivision.cpp b/Subdivision_method_3/examples/Subdivision_method_3/CatmullClark_subdivision.cpp index a03f453614b..017b198e2d5 100644 --- a/Subdivision_method_3/examples/Subdivision_method_3/CatmullClark_subdivision.cpp +++ b/Subdivision_method_3/examples/Subdivision_method_3/CatmullClark_subdivision.cpp @@ -1,10 +1,12 @@ #include #include +#include #include #include typedef CGAL::Simple_cartesian Kernel; typedef CGAL::Surface_mesh Polyhedron; +//typedef CGAL::Polyhedron_3 Polyhedron; using namespace std; using namespace CGAL; diff --git a/Subdivision_method_3/include/CGAL/Subdivision_mask_3.h b/Subdivision_method_3/include/CGAL/Subdivision_mask_3.h index 9b6f72dcf5f..5eacf2596f5 100644 --- a/Subdivision_method_3/include/CGAL/Subdivision_mask_3.h +++ b/Subdivision_method_3/include/CGAL/Subdivision_mask_3.h @@ -184,7 +184,7 @@ public: Point& ep2 = get(this->vpmap,target(opposite(edge, this->polyhedron), this->polyhedron)); ept = Point((ep1[0]+ep2[0])/2, (ep1[1]+ep2[1])/2, (ep1[2]+ep2[2])/2); - Halfedge_around_target_circulator vcir(target(edge, this->polyhedron), this->polyhedron); + Halfedge_around_target_circulator vcir(edge, this->polyhedron); Point& vp1 = get(this->vpmap,target(opposite(*vcir, this->polyhedron ), this->polyhedron)); Point& vp0 = get(this->vpmap, target(*vcir, this->polyhedron)); --vcir;