generate_sphere: Generate a spherical point cloud

Description Usage Arguments Value Examples

View source: R/generate_sphere.R

Description

Generate a spherical point cloud

Usage

1
generate_sphere(angular_res = 1, r = 1, sph = FALSE)

Arguments

angular_res

the angular resolution that sets the spacing between points.

r

numeric. The sphere radius.

sph

logical. If TRUE the spherical coordinates of the points are returned, if FALSE the XYZ coordinates are returned.

Value

a data.table containing points coordinates.

Examples

1
2
3
4
5
# generate a sphere
sph <- viewshed3d::generate_sphere()

# plot the sphere
rgl::plot3d(sph)

viewshed3d documentation built on April 4, 2021, 1:06 a.m.