Merge pull request #2929 from maxGimeno/Demo-Fix_selection_edge_to_face-GF

Polyhedron demo: Fix the selection edge to faces
This commit is contained in:
Laurent Rineau 2018-03-26 10:55:59 +02:00
commit 4f02b8c9f0
1 changed files with 5 additions and 2 deletions

View File

@ -635,9 +635,12 @@ public Q_SLOTS:
const Face_graph& poly = *selection_item->polyhedron();
BOOST_FOREACH(Scene_polyhedron_selection_item::fg_edge_descriptor ed, selection_item->selected_edges)
{
selection_item->selected_facets.insert(face(halfedge(ed, poly), poly));
if(!is_border_edge(halfedge(ed,poly), poly))
if(!is_border(halfedge(ed,poly), poly)){
selection_item->selected_facets.insert(face(halfedge(ed, poly), poly));
}
if(!is_border(opposite(halfedge(ed,poly), poly), poly)){
selection_item->selected_facets.insert(face(opposite(halfedge(ed, poly), poly), poly));
}
}
selection_item->invalidateOpenGLBuffers();
selection_item->itemChanged();