| spheres.mesh | R Documentation |
Merges one slightly refined icosphere per sphere into a single mesh, i.e., the result is a single surface with one connected component per input sphere. This is much cheaper to render (and to convert for the scimesh backend) than a list of hundreds of separate sphere meshes.
spheres.mesh(centers, radii = 1, subdivisions = 2L)
centers |
n x 3 numeric matrix, the sphere centers. |
radii |
numeric vector of length n or a single number, the sphere radii. |
subdivisions |
non-negative integer, the number of subdivisions of the unit icosphere, see |
an fs.surface instance (a mesh) with one component per sphere.
m = fsbrain:::spheres.mesh(rbind(c(0, 0, 0), c(10, 0, 0)), c(1, 2));
nrow(m$vertices);
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.