Subject: CGAL users discussion list
List archive
- From: jack64 <>
- To:
- Subject: [cgal-discuss] compiler problem using create_offset_polygons_2 (VS 2013)
- Date: Sun, 21 Sep 2014 00:14:18 -0700 (PDT)
Hi everyone,
I'm new in CGAL and I've a problem compiling a simple app that use
*create_offset_polygons_2*.
Code compile and run fine in /release mode/ while in /debug mode/ I've th
compiler output listed below.
Some idea?
Thanks!
*Code*
#include<vector>
#include<boost/shared_ptr.hpp>
#include<CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include<CGAL/Polygon_2.h>
#include<CGAL/create_offset_polygons_2.h>
#include "print.h"
typedef CGAL::Exact_predicates_inexact_constructions_kernel K;
typedef K::FT FT;
typedef K::Point_2 Point_2;
typedef CGAL::Polygon_2<K> Polygon_2;
typedef CGAL::Straight_skeleton_2<K> Ss;
typedef boost::shared_ptr<Polygon_2> PolygonPtr;
typedef boost::shared_ptr<Ss> SsPtr;
typedef std::vector<PolygonPtr> PolygonPtrVector;
int test()
{
Polygon_2 poly;
poly.push_back(Point_2(0, 0));
poly.push_back(Point_2(10, 0));
poly.push_back(Point_2(10, 10));
poly.push_back(Point_2(0, 10));
FT lOffset = 1;
PolygonPtrVector inner_offset_polygons =
CGAL::create_interior_skeleton_and_offset_polygons_2(lOffset, poly);
PolygonPtrVector outer_offset_polygons =
CGAL::create_exterior_skeleton_and_offset_polygons_2(lOffset, poly);
print_polygons(inner_offset_polygons);
print_polygons(outer_offset_polygons);
return 0;
}
Compiler output in DEBUG mode
1>------ Build started: Project: plyofs, Configuration: Debug x64 ------
1> plyofs.cpp
1>D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(229):
error C2665: 'CGAL::possibly' : none of the 2 overloads could convert all
the argument types
1> D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/assertions.h(60):
could be 'bool CGAL::possibly(CGAL::Uncertain<bool>)'
1> D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/assertions.h(59):
or 'bool CGAL::possibly(bool)'
1> while trying to match the argument list
'(boost::optional<CGAL::Point_2<Kernel_>>)'
1> with
1> [
1> Kernel_=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(221)
: while compiling class template member function 'void
CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::AddOffsetVertex(double,CGAL::internal::In_place_list_const_iterator<T,Alloc>,boost::shared_ptr<Polygon_2>)'
1> with
1> [
1>
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> ,
T=CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>
1> ,
Alloc=std::allocator<CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>>
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(271)
: see reference to function template instantiation 'void
CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::AddOffsetVertex(double,CGAL::internal::In_place_list_const_iterator<T,Alloc>,boost::shared_ptr<Polygon_2>)'
being compiled
1> with
1> [
1>
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> ,
T=CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>
1> ,
Alloc=std::allocator<CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>>
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(199)
: while compiling class template member function
'CGAL::internal::In_place_list_const_iterator<T,Alloc>
CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::LocateSeed(double)'
1> with
1> [
1>
T=CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>
1> ,
Alloc=std::allocator<CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>>
1> ,
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(324)
: see reference to function template instantiation
'CGAL::internal::In_place_list_const_iterator<T,Alloc>
CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::LocateSeed(double)'
being compiled
1> with
1> [
1>
T=CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>
1> ,
Alloc=std::allocator<CGAL::HalfedgeDS_in_place_list_halfedge<CGAL::Straight_skeleton_halfedge_base_2<CGAL::HalfedgeDS_list_types<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>,CGAL::Segment_2<CGAL::Epick>>>>
1> ,
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/Straight_skeleton_2/Polygon_offset_builder_2_impl.h(27)
: while compiling class template member function
'CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::Polygon_offset_builder_2(const
CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<_Ty>>
&,const CGAL::Polygon_offset_builder_traits_2<K> &,const
CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_> &)'
1> with
1> [
1>
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , _Ty=int
1> , K=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(164)
: see reference to function template instantiation
'CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>::Polygon_offset_builder_2(const
CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<_Ty>>
&,const CGAL::Polygon_offset_builder_traits_2<K> &,const
CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_> &)' being
compiled
1> with
1> [
1>
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , _Ty=int
1> , K=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(164)
: see reference to class template instantiation
'CGAL::Polygon_offset_builder_2<Skeleton,OffsetBuilderTraits,OutPolygon,CGAL::Default_polygon_offset_builder_2_visitor<Traits_,Ss_>>'
being compiled
1> with
1> [
1>
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OutPolygon=Polygon_2
1> , Traits_=OffsetBuilderTraits
1> ,
Ss_=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(189)
: see reference to function template instantiation
'std::vector<PolygonPtr,std::allocator<_Ty>>
CGAL::CGAL_SS_i::create_offset_polygons_2<Polygon,FT,Skeleton,K>(const FT
&,const Skeleton &,const K &,CGAL::Tag_true)' being compiled
1> with
1> [
1> _Ty=PolygonPtr
1> , Polygon=Polygon_2
1> , FT=FT
1> ,
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , K=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(246)
: see reference to function template instantiation
'std::vector<PolygonPtr,std::allocator<_Ty>>
CGAL::create_offset_polygons_2<Polygon,FT,Skeleton,OfK>(const FT &,const
Skeleton &,const K &)' being compiled
1> with
1> [
1> _Ty=PolygonPtr
1> , Polygon=Polygon_2
1> , FT=FT
1> ,
Skeleton=CGAL::Straight_skeleton_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Straight_skeleton_items_2,std::allocator<int>>
1> , OfK=CGAL::Epick
1> , K=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(296)
: see reference to function template instantiation
'std::vector<PolygonPtr,std::allocator<_Ty>>
CGAL::create_interior_skeleton_and_offset_polygons_2<FT,Polygon,std::_Vector_iterator<std::_Vector_val<std::_Simple_types<CGAL::Polygon_2<K,std::vector<CGAL::Point_2<Kernel_>,std::allocator<CGAL::Point_2<Kernel_>>>>>>>,OfK,CGAL::Epick>(const
FT &,const Polygon &,HoleIterator,HoleIterator,const OfK &,const SsK &)'
being compiled
1> with
1> [
1> _Ty=PolygonPtr
1> , FT=FT
1> , Polygon=Polygon_2
1> , Kernel_=CGAL::Epick
1> , OfK=CGAL::Epick
1> ,
HoleIterator=std::_Vector_iterator<std::_Vector_val<std::_Simple_types<CGAL::Polygon_2<K,std::vector<CGAL::Point_2<CGAL::Epick>,std::allocator<CGAL::Point_2<CGAL::Epick>>>>>>>
1> , SsK=CGAL::Epick
1> ]
1>
D:\3rdPartyLibrary\CGAL\CGAL-4.4\include\CGAL/create_offset_polygons_2.h(304)
: see reference to function template instantiation
'std::vector<PolygonPtr,std::allocator<_Ty>>
CGAL::create_interior_skeleton_and_offset_polygons_2<FT,Polygon,CGAL::Epick>(const
FT &,const Polygon &,const OfK &)' being compiled
1> with
1> [
1> _Ty=PolygonPtr
1> , FT=FT
1> , Polygon=Polygon_2
1> , OfK=CGAL::Epick
1> ]
1> plyofs.cpp(29) : see reference to function template
instantiation 'std::vector<PolygonPtr,std::allocator<_Ty>>
CGAL::create_interior_skeleton_and_offset_polygons_2<FT,Polygon_2>(const FT
&,const Polygon &)' being compiled
1> with
1> [
1> _Ty=PolygonPtr
1> , FT=FT
1> , Polygon=Polygon_2
1> ]
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/compiler-problem-using-create-offset-polygons-2-VS-2013-tp4659857.html
Sent from the cgal-discuss mailing list archive at Nabble.com.
- [cgal-discuss] compiler problem using create_offset_polygons_2 (VS 2013), jack64, 09/21/2014
- Re: [cgal-discuss] compiler problem using create_offset_polygons_2 (VS 2013), Rostislav Khlebnikov, 09/21/2014
- Re: [cgal-discuss] compiler problem using create_offset_polygons_2 (VS 2013), jack64, 09/21/2014
- Re: [cgal-discuss] compiler problem using create_offset_polygons_2 (VS 2013), Rostislav Khlebnikov, 09/21/2014
Archive powered by MHonArc 2.6.18.