diff --git a/Mesh_3/include/CGAL/Mesh_constant_domain_field_3.h b/Mesh_3/include/CGAL/Mesh_constant_domain_field_3.h index 0255ca2f47f..297467c0171 100644 --- a/Mesh_3/include/CGAL/Mesh_constant_domain_field_3.h +++ b/Mesh_3/include/CGAL/Mesh_constant_domain_field_3.h @@ -30,7 +30,7 @@ #include #include -#include +#include namespace CGAL { diff --git a/Triangulation/include/CGAL/internal/Triangulation/Has_nested_type_Bare_point.h b/STL_Extension/include/CGAL/internal/Has_nested_type_Bare_point.h similarity index 63% rename from Triangulation/include/CGAL/internal/Triangulation/Has_nested_type_Bare_point.h rename to STL_Extension/include/CGAL/internal/Has_nested_type_Bare_point.h index e51b4705079..9a01b61e148 100644 --- a/Triangulation/include/CGAL/internal/Triangulation/Has_nested_type_Bare_point.h +++ b/STL_Extension/include/CGAL/internal/Has_nested_type_Bare_point.h @@ -2,10 +2,10 @@ // Copyright (c) 2016 GeometryFactory Sarl (France) // All rights reserved. // -// This file is part of CGAL (www.cgal.org). -// You can redistribute it and/or modify it under the terms of the GNU -// General Public License as published by the Free Software Foundation, -// either version 3 of the License, or (at your option) any later version. +// This file is part of CGAL (www.cgal.org); you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License as +// published by the Free Software Foundation; either version 3 of the License, +// or (at your option) any later version. // // Licensees holding a valid commercial license may use this file in // accordance with the commercial license agreement provided with the software. @@ -13,14 +13,10 @@ // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. // -// // Author(s) : Jane Tournois -#ifndef CGAL_TRIANGULATION_HAS_NESTED_TYPE_BARE_POINT_H -#define CGAL_TRIANGULATION_HAS_NESTED_TYPE_BARE_POINT_H - -#include - +#ifndef CGAL_HAS_NESTED_TYPE_BARE_POINT_H +#define CGAL_HAS_NESTED_TYPE_BARE_POINT_H #include @@ -40,4 +36,4 @@ namespace CGAL { } // end namespace internal } // end namespace CGAL -#endif // CGAL_TRIANGULATION_HAS_NESTED_TYPE_BARE_POINT_H +#endif // CGAL_HAS_NESTED_TYPE_BARE_POINT_H diff --git a/Triangulation_2/include/CGAL/internal/info_check.h b/STL_Extension/include/CGAL/internal/info_check.h similarity index 74% rename from Triangulation_2/include/CGAL/internal/info_check.h rename to STL_Extension/include/CGAL/internal/info_check.h index 51c7370a70e..4b09d46a85b 100644 --- a/Triangulation_2/include/CGAL/internal/info_check.h +++ b/STL_Extension/include/CGAL/internal/info_check.h @@ -1,10 +1,10 @@ // Copyright (c) 2010 GeometryFactory (France). // All rights reserved. // -// This file is part of CGAL (www.cgal.org). -// You can redistribute it and/or modify it under the terms of the GNU -// General Public License as published by the Free Software Foundation, -// either version 3 of the License, or (at your option) any later version. +// This file is part of CGAL (www.cgal.org); you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License as +// published by the Free Software Foundation; either version 3 of the License, +// or (at your option) any later version. // // Licensees holding a valid commercial license may use this file in // accordance with the commercial license agreement provided with the software. @@ -22,8 +22,6 @@ #ifndef CGAL_INTERNAL_INFO_CHECK_H #define CGAL_INTERNAL_INFO_CHECK_H -#include - #include diff --git a/Triangulation_2/include/CGAL/triangulation_assertions.h b/STL_Extension/include/CGAL/triangulation_assertions.h similarity index 97% rename from Triangulation_2/include/CGAL/triangulation_assertions.h rename to STL_Extension/include/CGAL/triangulation_assertions.h index c3bdcab5fe4..849d0a1599f 100644 --- a/Triangulation_2/include/CGAL/triangulation_assertions.h +++ b/STL_Extension/include/CGAL/triangulation_assertions.h @@ -1,10 +1,9 @@ -// Copyright (c) 2001 INRIA Sophia-Antipolis (France). -// All rights reserved. +// Copyright (c) 2001 INRIA Sophia-Antipolis (France). All rights reserved. // -// This file is part of CGAL (www.cgal.org). -// You can redistribute it and/or modify it under the terms of the GNU -// General Public License as published by the Free Software Foundation, -// either version 3 of the License, or (at your option) any later version. +// This file is part of CGAL (www.cgal.org); you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License as +// published by the Free Software Foundation; either version 3 of the License, +// or (at your option) any later version. // // Licensees holding a valid commercial license may use this file in // accordance with the commercial license agreement provided with the software. @@ -40,7 +39,6 @@ || defined(NDEBUG) # define CGAL_triangulation_assertion(EX) (static_cast(0)) -#include # define CGAL_triangulation_assertion_msg(EX,MSG) (static_cast(0)) # define CGAL_triangulation_assertion_code(CODE) diff --git a/Triangulation_2/include/CGAL/Regular_triangulation_2.h b/Triangulation_2/include/CGAL/Regular_triangulation_2.h index ba4c272ccf5..981de75d85e 100644 --- a/Triangulation_2/include/CGAL/Regular_triangulation_2.h +++ b/Triangulation_2/include/CGAL/Regular_triangulation_2.h @@ -30,7 +30,7 @@ #include #include #include -#include +#include #include #include diff --git a/Triangulation_3/include/CGAL/Regular_triangulation_3.h b/Triangulation_3/include/CGAL/Regular_triangulation_3.h index efe990eb86a..d4feeb8cefd 100644 --- a/Triangulation_3/include/CGAL/Regular_triangulation_3.h +++ b/Triangulation_3/include/CGAL/Regular_triangulation_3.h @@ -53,7 +53,7 @@ struct Weighted_point_mapper_3 #include #include #include -#include +#include #include #include diff --git a/Triangulation_3/include/CGAL/Triangulation_utils_3.h b/Triangulation_3/include/CGAL/Triangulation_utils_3.h index 62a1ee71eb0..1676faf6629 100644 --- a/Triangulation_3/include/CGAL/Triangulation_utils_3.h +++ b/Triangulation_3/include/CGAL/Triangulation_utils_3.h @@ -25,7 +25,6 @@ #include #include -#include namespace CGAL { @@ -36,6 +35,10 @@ struct Triangulation_utils_base_3 { static const char tab_next_around_edge[4][4]; static const int tab_vertex_triple_index[4][3]; + + // copied from Triangulation_utils_2.h to avoid package dependency + static const int ccw_map[3]; + static const int cw_map[3]; }; template < class T > @@ -53,14 +56,31 @@ const int Triangulation_utils_base_3::tab_vertex_triple_index[4][3] = { {0, 1, 2} }; +template < class T > +const int Triangulation_utils_base_3::ccw_map[3] = {1, 2, 0}; + +template < class T > +const int Triangulation_utils_base_3::cw_map[3] = {2, 0, 1}; + // We derive from Triangulation_cw_ccw_2 because we still use cw() and ccw() // in the 2D part of the code. Ideally, this should go away when we re-use // T2D entirely. struct Triangulation_utils_3 - : public Triangulation_cw_ccw_2, - public Triangulation_utils_base_3<> + : public Triangulation_utils_base_3<> { + static int ccw(const int i) + { + CGAL_triangulation_precondition( i >= 0 && i < 3); + return ccw_map[i]; + } + + static int cw(const int i) + { + CGAL_triangulation_precondition( i >= 0 && i < 3); + return cw_map[i]; + } + static int next_around_edge(const int i, const int j) { // index of the next cell when turning around the diff --git a/Triangulation_3/test/Triangulation_3/test_dependencies.h b/Triangulation_3/test/Triangulation_3/test_dependencies.h index 8ccca2a691e..9bbb8f53e98 100644 --- a/Triangulation_3/test/Triangulation_3/test_dependencies.h +++ b/Triangulation_3/test/Triangulation_3/test_dependencies.h @@ -5,5 +5,4 @@ #define CGAL_LICENSE_ERROR #define CGAL_TRIANGULATION_3_COMMERCIAL_LICENSE 22222222 -#define CGAL_TRIANGULATION_2_COMMERCIAL_LICENSE 22222222 #define CGAL_TDS_3_COMMERCIAL_LICENSE 22222222 diff --git a/Triangulation_3/test/Triangulation_3/test_regular_insert_range_with_info.cpp b/Triangulation_3/test/Triangulation_3/test_regular_insert_range_with_info.cpp index 49528c3a663..8d4e95022f5 100644 --- a/Triangulation_3/test/Triangulation_3/test_regular_insert_range_with_info.cpp +++ b/Triangulation_3/test/Triangulation_3/test_regular_insert_range_with_info.cpp @@ -1,3 +1,5 @@ + +#include "test_dependencies.h" #include #include #include