Lloyd optimize with 'CGAL::Triangulation_vertex_base_with_info_2

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Lloyd optimize with 'CGAL::Triangulation_vertex_base_with_info_2

Dinesh
Hi
I am trying to optimize the mesh I obtain after I perform delauny refinement as shown below

CGAL::refine_Delaunay_mesh_2(cdtp, seed.begin(), seed.end(), Criteria( cnfg_.MaxTriangleSkewness(), cnfg_.MaxTriangleEdgeLength()*2.0));
if(OptimizeMesh)
{
CGAL::lloyd_optimize_mesh_2(cdtp ,CGAL::parameters::max_iteration_number = MeshOptItr);
}

However I get a compiler error as shown below
3>D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(379): error C2039: 'sizing_info' : is not a member of 'CGAL::Triangulation_vertex_base_with_info_2<Info_,GT,Vb>'
3>          with
3>          [
3>              Info_=std::pair<std::pair<int,int>,std::pair<int,IdType>>,
3>              GT=Kernel,
3>              Vb=CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>
3>          ]
3>          D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(371) : while compiling class template member function 'void CGAL::Mesh_2::Mesh_global_optimizer_2<CDT,MoveFunction>::update_mesh(const std::vector<_Ty> &)'
3>          with
3>          [
3>              CDT=CGAL::Constrained_triangulation_plus_2<CDTriangulation>,
3>              MoveFunction=Mv,
3>              _Ty=std::pair<CGAL::internal::CC_iterator<CGAL::Compact_container<CGAL::Triangulation_vertex_base_with_info_2<std::pair<std::pair<int,int>,std::pair<int,IdType>>,Kernel,CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>>>,false>,CGAL::Point_2<CGAL::Epick>>
3>          ]
3>          D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(178) : see reference to function template instantiation 'void CGAL::Mesh_2::Mesh_global_optimizer_2<CDT,MoveFunction>::update_mesh(const std::vector<_Ty> &)' being compiled
3>          with
3>          [
3>              CDT=CGAL::Constrained_triangulation_plus_2<CDTriangulation>,
3>              MoveFunction=Mv,
3>              _Ty=std::pair<CGAL::internal::CC_iterator<CGAL::Compact_container<CGAL::Triangulation_vertex_base_with_info_2<std::pair<std::pair<int,int>,std::pair<int,IdType>>,Kernel,CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>>>,false>,CGAL::Point_2<CGAL::Epick>>
3>          ]

I use visual studio 2012 on windows 7
Any help appreciated..
Regards
Dinesh
Reply | Threaded
Open this post in threaded view
|

Re: Lloyd optimize with 'CGAL::Triangulation_vertex_base_with_info_2

Sebastien Loriot (GeometryFactory)
Answered here:

https://stackoverflow.com/questions/49948159/lloyd-optimization-using-cgal-4-12-beta2/49975801#49975801

On 04/20/2018 08:54 PM, Dinesh Shetty wrote:

> Hi
> I am trying to optimize the mesh I obtain after I perform delauny
> refinement as shown below
>
> CGAL::refine_Delaunay_mesh_2(cdtp, seed.begin(), seed.end(), Criteria(
> cnfg_.MaxTriangleSkewness(), cnfg_.MaxTriangleEdgeLength()*2.0));
> if(OptimizeMesh)
> {
> CGAL::lloyd_optimize_mesh_2(cdtp ,CGAL::parameters::max_iteration_number
> = MeshOptItr);
> }
>
> However I get a compiler error as shown below
> 3>D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(379):
> error C2039: 'sizing_info' : is not a member of
> 'CGAL::Triangulation_vertex_base_with_info_2<Info_,GT,Vb>'
> 3>          with
> 3>          [
> 3>              Info_=std::pair<std::pair<int,int>,std::pair<int,IdType>>,
> 3>              GT=Kernel,
> 3>              
> Vb=CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>
> 3>          ]
> 3>          
> D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(371)
> : while compiling class template member function 'void
> CGAL::Mesh_2::Mesh_global_optimizer_2<CDT,MoveFunction>::update_mesh(const
> std::vector<_Ty> &)'
> 3>          with
> 3>          [
> 3>              CDT=CGAL::Constrained_triangulation_plus_2<CDTriangulation>,
> 3>              MoveFunction=Mv,
> 3>              
> _Ty=std::pair<CGAL::internal::CC_iterator<CGAL::Compact_container<CGAL::Triangulation_vertex_base_with_info_2<std::pair<std::pair<int,int>,std::pair<int,IdType>>,Kernel,CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>>>,false>,CGAL::Point_2<CGAL::Epick>>
> 3>          ]
> 3>          
> D:\PE\PE_Software\3rdParty\CGAL\CGAL-4.12-beta2\include\CGAL/Mesh_2/Mesh_global_optimizer_2.h(178)
> : see reference to function template instantiation 'void
> CGAL::Mesh_2::Mesh_global_optimizer_2<CDT,MoveFunction>::update_mesh(const
> std::vector<_Ty> &)' being compiled
> 3>          with
> 3>          [
> 3>              CDT=CGAL::Constrained_triangulation_plus_2<CDTriangulation>,
> 3>              MoveFunction=Mv,
> 3>              
> _Ty=std::pair<CGAL::internal::CC_iterator<CGAL::Compact_container<CGAL::Triangulation_vertex_base_with_info_2<std::pair<std::pair<int,int>,std::pair<int,IdType>>,Kernel,CGAL::Triangulation_vertex_base_2<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_ds_vertex_base_2<CGAL::Triangulation_data_structure_2<Vertex_base,Face_base>>>>>,false>,CGAL::Point_2<CGAL::Epick>>
> 3>          ]
>
> I use visual studio 2012 on windows 7
> Any help appreciated..
> Regards
> Dinesh

--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://sympa.inria.fr/sympa/info/cgal-discuss