【发布时间】:2014-05-15 12:58:39
【问题描述】:
我正在尝试为每个顶点计算 3D 网格上的高斯曲率,所以我想知道顶点是否在边界上,我查看了 CGAL 在线手册,找不到检查顶点是否打开的方法边框,所以我写了一个函数,它循环遍历顶点周围的半边来检查这个,代码是:
bool is_border(Vertex_iterator& vi){
HV_circulator hv = vi-> vertex_begin();
//move around the vertex and check if there is a halfedge which
//is on border
for(; hv != vi -> vertex_begin(); vi++){
if(hv -> is_border())
return true;
}
return false;
}
所以我的问题是,有没有其他方法可以检查顶点是否在边界上?
【问题讨论】: