mirror of https://github.com/CGAL/cgal
Merge branch 'SLS-API_fixes-GF' into SLS-API_fixes-6.0.x-GF
This commit is contained in:
commit
bba9db1ff7
|
|
@ -22,10 +22,13 @@
|
||||||
#include <CGAL/Straight_skeleton_2/IO/print.h>
|
#include <CGAL/Straight_skeleton_2/IO/print.h>
|
||||||
#include <CGAL/Timer.h>
|
#include <CGAL/Timer.h>
|
||||||
|
|
||||||
#include <memory>
|
#include <CGAL/use.h>
|
||||||
|
|
||||||
|
#include <boost/shared_ptr.hpp>
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
#include <memory>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
|
|
@ -1128,6 +1131,7 @@ void test_kernel()
|
||||||
std::cerr.precision(17);
|
std::cerr.precision(17);
|
||||||
|
|
||||||
void (*dummy_ptr)() = &test_API<K>;
|
void (*dummy_ptr)() = &test_API<K>;
|
||||||
|
CGAL_USE(dummy_ptr);
|
||||||
|
|
||||||
// Artificial data
|
// Artificial data
|
||||||
test_offset_square<K>();
|
test_offset_square<K>();
|
||||||
|
|
|
||||||
|
|
@ -34,10 +34,13 @@ void Straight_skeleton_traits_external_trace(std::string m)
|
||||||
#include <CGAL/Polygon_2.h>
|
#include <CGAL/Polygon_2.h>
|
||||||
#include <CGAL/draw_polygon_2.h>
|
#include <CGAL/draw_polygon_2.h>
|
||||||
|
|
||||||
#include <memory>
|
#include <CGAL/use.h>
|
||||||
|
|
||||||
|
#include <boost/shared_ptr.hpp>
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
#include <memory>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
@ -222,6 +225,7 @@ void test_kernel()
|
||||||
// CGAL_STSKEL_TRAITS_ENABLE_TRACE
|
// CGAL_STSKEL_TRAITS_ENABLE_TRACE
|
||||||
|
|
||||||
void (*dummy_ptr)() = &test_API<K>;
|
void (*dummy_ptr)() = &test_API<K>;
|
||||||
|
CGAL_USE(dummy_ptr);
|
||||||
|
|
||||||
test_skeleton<K>("data/pseudo_split_0.poly", 13, 40, 8);
|
test_skeleton<K>("data/pseudo_split_0.poly", 13, 40, 8);
|
||||||
test_skeleton<K>("data/pseudo_split_1.poly", 21, 68, 12);
|
test_skeleton<K>("data/pseudo_split_1.poly", 21, 68, 12);
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,8 @@
|
||||||
#include <CGAL/Polygon_with_holes_2.h>
|
#include <CGAL/Polygon_with_holes_2.h>
|
||||||
#include <CGAL/Straight_skeleton_2/IO/print.h>
|
#include <CGAL/Straight_skeleton_2/IO/print.h>
|
||||||
|
|
||||||
|
#include <CGAL/use.h>
|
||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
|
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
|
|
@ -271,6 +273,7 @@ template <typename K>
|
||||||
void test_kernel()
|
void test_kernel()
|
||||||
{
|
{
|
||||||
void (*dummy_ptr)() = &test_API<K>;
|
void (*dummy_ptr)() = &test_API<K>;
|
||||||
|
CGAL_USE(dummy_ptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int, char**)
|
int main(int, char**)
|
||||||
|
|
|
||||||
|
|
@ -18,6 +18,8 @@
|
||||||
#include <CGAL/create_weighted_offset_polygons_2.h>
|
#include <CGAL/create_weighted_offset_polygons_2.h>
|
||||||
#include <CGAL/extrude_skeleton.h>
|
#include <CGAL/extrude_skeleton.h>
|
||||||
|
|
||||||
|
#include <CGAL/use.h>
|
||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
@ -62,7 +64,6 @@ void test_kernel(const int polygon_nv, CGAL::Random& rnd)
|
||||||
{
|
{
|
||||||
using FT = typename K::FT;
|
using FT = typename K::FT;
|
||||||
using Point_2 = typename K::Point_2;
|
using Point_2 = typename K::Point_2;
|
||||||
using Vector_2 = typename K::Vector_2;
|
|
||||||
using Point_3 = typename K::Point_3;
|
using Point_3 = typename K::Point_3;
|
||||||
|
|
||||||
using Polygon_2 = CGAL::Polygon_2<K>;
|
using Polygon_2 = CGAL::Polygon_2<K>;
|
||||||
|
|
@ -73,6 +74,7 @@ void test_kernel(const int polygon_nv, CGAL::Random& rnd)
|
||||||
using Mesh = CGAL::Surface_mesh<Point_3>;
|
using Mesh = CGAL::Surface_mesh<Point_3>;
|
||||||
|
|
||||||
void (*dummy_ptr)() = &test_API<K>;
|
void (*dummy_ptr)() = &test_API<K>;
|
||||||
|
CGAL_USE(dummy_ptr);
|
||||||
|
|
||||||
typedef CGAL::Random_points_in_square_2<Point_2> Point_generator;
|
typedef CGAL::Random_points_in_square_2<Point_2> Point_generator;
|
||||||
Polygon_2 pol;
|
Polygon_2 pol;
|
||||||
|
|
@ -92,7 +94,7 @@ void test_kernel(const int polygon_nv, CGAL::Random& rnd)
|
||||||
|
|
||||||
CGAL::draw(pol);
|
CGAL::draw(pol);
|
||||||
|
|
||||||
auto ss_ptr = CGAL::create_interior_weighted_straight_skeleton_2(pol, weights);
|
Straight_skeleton_2_ptr ss_ptr = CGAL::create_interior_weighted_straight_skeleton_2(pol, weights, K());
|
||||||
assert(ss_ptr);
|
assert(ss_ptr);
|
||||||
if(!ss_ptr)
|
if(!ss_ptr)
|
||||||
{
|
{
|
||||||
|
|
@ -102,7 +104,7 @@ void test_kernel(const int polygon_nv, CGAL::Random& rnd)
|
||||||
|
|
||||||
CGAL::draw(*ss_ptr);
|
CGAL::draw(*ss_ptr);
|
||||||
|
|
||||||
ss_ptr = CGAL::create_exterior_weighted_straight_skeleton_2(0.1, pol, weights);
|
ss_ptr = CGAL::create_exterior_weighted_straight_skeleton_2(0.1, pol, weights, K());
|
||||||
assert(ss_ptr);
|
assert(ss_ptr);
|
||||||
if(!ss_ptr)
|
if(!ss_ptr)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ void test_kernel(const int hole_n, const int hole_nv, CGAL::Random& rnd)
|
||||||
typedef CGAL::Random_points_in_square_2<Point_2> Point_generator;
|
typedef CGAL::Random_points_in_square_2<Point_2> Point_generator;
|
||||||
|
|
||||||
Polygon_2 poly;
|
Polygon_2 poly;
|
||||||
CGAL::random_polygon_2(10, std::back_inserter(poly), Point_generator(0.25, rnd));
|
CGAL::random_polygon_2(hole_nv, std::back_inserter(poly), Point_generator(0.25, rnd));
|
||||||
return poly;
|
return poly;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -113,7 +113,7 @@ void test_kernel(const int hole_n, const int hole_nv, CGAL::Random& rnd)
|
||||||
|
|
||||||
// CGAL::draw(pwh);
|
// CGAL::draw(pwh);
|
||||||
|
|
||||||
auto ss_ptr = CGAL::create_interior_weighted_straight_skeleton_2(pwh, weights);
|
Straight_skeleton_2_ptr ss_ptr = CGAL::create_interior_weighted_straight_skeleton_2(pwh, weights, K());
|
||||||
assert(ss_ptr);
|
assert(ss_ptr);
|
||||||
if(!ss_ptr)
|
if(!ss_ptr)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue