我在生成的网格中存在四面体质量低的问题。
我使用CGAL::Delaunay_Triangulation_3进行三角剖分,来自预定义的点云.
我的问题是,由CGAL生成的元素有点低质量
因为我有‘点云’形式的网格,所以我没有Mesh_Domain_3,所有关于网格优化的例子都使用了make_mesh_3和Mesh_Domain。
是否有任何方法可以使用CGAL对生成的delaunay网格进行平滑处理,或者自定义CGAL::Delaunay_triangulation_3进行优化?但是有一个限制--网格中的一些点不能从云中移动/删除,而有些点可以。
我使用的类型:
typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
typedef CGAL::Triangulation_vertex_base_with_info_3<int, Kernel> Vb;
typedef CGAL::Triangulation_data_structure_3<Vb> Tds;
typedef CGAL::Delaunay_triangulation_3<Kernel, Tds> Delaunay;生成码
Delaunay triangulation(nodes.begin(), nodes.end());
//woudld be best to apply mesh smoothing here.
for(auto fit = triangulation.finite_cells_begin(); fit != triangulation.finite_cells_end(); ++fit)
{
auto x1 = fit->vertex(0)->info();
auto x2 = fit->vertex(1)->info();
auto x3 = fit->vertex(2)->info();
auto x4 = fit->vertex(3)->info();
tetras.push_back(new Tetrahedron(nodesToTriangulate[x1],nodesToTriangulate[x2],nodesToTriangulate[x3],nodesToTriangulate[x4]));
}发布于 2015-10-20 16:56:19
为了提高网格中四面体的质量,我决定采用约束拉普拉斯平滑+拓扑平滑方差。我不得不自己实现这些平滑,因为它们在CGAL中是不可用的。
这大大提高了网格的质量。关于质量,我指的是四面体的最小立体角。
发布于 2015-09-20 06:40:32
你可以计算每一个四角子的重心,用一个加权三角剖分来检索。
https://stackoverflow.com/questions/32672900
复制相似问题