checkFaceOrientation | R Documentation |
check the orientation of a mesh assuming that expansion along normals increases centroid size
checkFaceOrientation(x, offset = NULL)
x |
mesh of class mesh3d |
offset |
numeric: amount to offset the mesh along the vertex normals. If NULL a reasonable value will be estimated. |
assuming that a correctly (i.e outward) oriented mesh increases its centroid size when 'growing' outwards, this function tests whether this is the case.
returns TRUE if mesh is oriented correctly and FALSE otherwise
data(dummyhead)
## now we invert faces inwards
checkFaceOrientation(dummyhead.mesh)
if (requireNamespace("Morpho", quietly = TRUE)) {
dummyinward <- Morpho::invertFaces(dummyhead.mesh)
checkFaceOrientation(dummyinward)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.