Get all edges of a triangular mesh
Extract all edges from a mesh and retrieve adjacent faces and vertices
vcgGetEdge(mesh, unique = TRUE)
mesh |
triangular mesh of class 'mesh3d' |
unique |
logical: if TRUE each edge is only reported once, if FALSE, all occurences are reported. |
returns a dataframe containing:
vert1 |
integer indicating the position of the first vertex belonging to this edge |
vert2 |
integer indicating the position of the second vertex belonging to this edge |
facept |
integer pointing to the (or a, if unique = TRUE) face adjacent to the edge |
border |
integer indicating if the edge is at the border of the mesh. 0 = no border, 1 = border |
require(rgl) data(humface) edges <-vcgGetEdge(humface) ## Not run: ## show first edge lines3d(t(humface$vb[1:3,])[c(edges$vert1[1],edges$vert2[2]),],col=2,lwd=3) shade3d(humface, col=3) ## now find the edge - hint: it is at the neck. ## End(Not run)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.