tube_Surface_Mesh: Create surface mesh of a tube

View source: R/ETRep_Functions.R

tube_Surface_MeshR Documentation

Create surface mesh of a tube

Description

Create surface mesh of a tube

Usage

tube_Surface_Mesh(
  tube,
  meshType = "quadrilateral",
  plotMesh = TRUE,
  color = "blue",
  decorate = TRUE
)

Arguments

tube

List containing ETRep details.

meshType

String, either "quadrilateral" or "triangular" definig the type of mesh.

plotMesh

Logical, enables plotting of the mesh (default is TRUE).

color

String, defining the color of the mesh (default is 'blue').

decorate

Logical, enables decorating the plot (default is TRUE).

Value

An object from rgl::mesh3d class

Examples

## Not run: 
quad_mesh<-tube_Surface_Mesh(tube = ETRep::tube_B, 
                             meshType = "quadrilateral", 
                             plotMesh = TRUE, 
                             decorate = TRUE, 
                             color = "orange")
# draw wireframe of the mesh
rgl::wire3d(quad_mesh, color = "black", lwd = 1)   # add wireframe
# Display in browser
ETRep:::.etrep_show3d(width = 800, height = 600)

tri_mesh<-tube_Surface_Mesh(tube = ETRep::tube_B, 
                            meshType = "triangular", 
                            plotMesh = TRUE, 
                            decorate = TRUE, 
                            color = "green")
# draw wireframe of the mesh
rgl::wire3d(tri_mesh, color = "black", lwd = 1)   # add wireframe
# Display in browser
ETRep:::.etrep_show3d(width = 800, height = 600)
 
## End(Not run)

ETRep documentation built on Nov. 5, 2025, 6:34 p.m.