rgl.material {rgl}R Documentation

generic Appearance setup

Description

Set material properties for geometry appearance.

Usage

rgl.material(
  color        = c("white"),
  alpha        = c(1.0),
  lit          = TRUE, 
  ambient      = "black",
  specular     = "white", 
  emission     = "black", 
  shininess    = 50.0, 
  smooth       = TRUE,
  texture      = NULL, 
  textype      = "rgb", 
  texmipmap    = FALSE, 
  texminfilter = "linear", 
  texmagfilter = "linear",
  texenvmap    = FALSE,
  front        = "fill", 
  back         = "fill",
  size         = 1.0, 
  fog          = TRUE
)

Arguments

color vector of R color characters. Represents the diffuse component in case of lighting calculation (lit = TRUE), otherwise it describes the solid color characteristics.
lit logical, specifying if lighting calculation should take place on geometry
ambient, specular, emission, shininess properties for lighting calculation. ambient, specular, emission are R color character string values; shininess represents a numerical.
alpha vector of alpha values between 0.0 (fully transparent) .. 1.0 (opaque).
smooth logical, specifying whether gourad shading (smooth) or flat shading should be used.
texture path to a texture image file. Supported formats: png.
textype specifies what is defined with the pixmap
"alpha"
alpha values
"luminance"
luminance
"luminance.alpha"
luminance and alpha
"rgb"
color
"rgba"
color and alpha texture
texmipmap Logical, specifies if the texture should be mipmapped.
texmagfilter specifies the magnification filtering type (sorted by ascending quality):
"nearest"
texel nearest to the center of the pixel
"linear"
weighted linear average of a 2x2 array of texels
texminfilter specifies the minification filtering type (sorted by ascending quality):
"nearest"
texel nearest to the center of the pixel
"linear"
weighted linear average of a 2x2 array of texels
"nearest.mipmap.nearest"
low quality mipmapping
"nearest.mipmap.linear"
medium quality mipmapping
"linear.mipmap.nearest"
medium quality mipmapping
"linear.mipmap.linear"
high quality mipmapping
texenvmap logical, specifies if auto-generated texture coordinates for environment-mapping should be performed on geometry.
front, back Determines the polygon mode for the specified side:
"fill"
filled polygon
"line"
wireframed polygon
"points"
point polygon
"cull"
culled (hidden) polygon
size numeric, specifying the line and point size.
fog logical, specifying if fog effect should be applied on the corresponding shape

Details

Only one side at a time can be culled.

See Also

rgl.primitive, rgl.bbox, rgl.bg, rgl.light


[Package rgl version 0.65 Index]