display.3D.mesh | R Documentation |
The display.3D.mesh
function performs a 3D display of a mesh.
display.3D.mesh(mesh, display.ref = mesh$ref.pseudo, T.MAT = NULL, ...)
mesh |
"mesh" class object, created by the mesh.from.bin function. See espadon.class for class definitions. |
display.ref |
Character string. Pseudonym of the frame of reference used for display. |
T.MAT |
"t.mat" class object, created by load.patient.from.Rdcm or
load.T.MAT. If |
... |
Additional arguments passed to shade3d as |
Returns a display of mesh
in the current RGL window if it exists,
in a new window otherwise.
mesh.from.bin.
# loading of toy-patient objects (decrease dxyz for better result)
step <- 4
patient <- toy.load.patient (modality = c("ct", "rtstruct"), roi.name = "",
dxyz = rep (step, 3))
CT <- patient$ct[[1]]
S <- patient$rtstruct[[1]]
# creation of the patient mesh
bin <- bin.from.roi (CT, struct = S, roi.name = "patient", verbose = FALSE)
mesh.patient <- mesh.from.bin (bin, alias = "patient", verbose = FALSE)
# display of the patient mesh, with transparency
rgl::open3d()
display.3D.mesh (mesh.patient, color = "burlywood2", specular = "#404040")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.