Create surface forms from matrix or 'raster' data for flexible plotting and conversion to other mesh types. The functions 'quadmesh' or 'triangmesh' produce a continuous surface as a 'mesh3d' object as used by the 'rgl' package. This is used for plotting raster data in 3D (optionally with texture), and allows the application of a map projection without data loss. There are discrete forms of these continuous surfaces available with 'dquadmesh' and 'dtriangmesh' functions.
Build a quadmesh in R.
library(quadmesh)library(raster)data(volcano)r <- setExtent(raster(volcano), extent(0, 100, 0, 200))qm <- quadmesh(r)library(rgl)scl <- function(x) (x - min(x))/diff(range(x))shade3d(qm, col = grey(scl(qm$vb[3,qm$ib])))
basic quadrangle mesh support
NEWS.md file to track changes to the package.