| svg.bboxLight {svgViewR} | R Documentation | 
Adds light(s) to Viewer
Description
Adds point light(s) in Viewer at corners of bounding box.
Usage
svg.bboxLight(x=c(1,1,1), col='#FFFFDD', intensity=1, distance=3, hidden = TRUE)
Arguments
| x | The corner(s) where a light source (vector) or multiple light sources (matrix) should be added. | 
| col | The color of the light. | 
| intensity | The intensity of the light. | 
| distance | The distance from the light where the intensity is 0. | 
| A logical indicating whether the light source location should be indicated by a yellow sphere. By default the sphere is hidden. Setting this to  | 
Details
This function only works in the webgl plotting mode (i.e. when the mode parameter of svg.new is 'webgl'). This function creates a point light (if x is a vector) or lights (if x is a matrix) in the Viewer scene at the specified coordinates (x). The point light is the PointLight object in the three.js library.
Value
NULL
Author(s)
Aaron Olsen
See Also
Examples
## Not run: 
# Create new Viewer
svg.new(mode='webgl')
# Add object
svg.cylinder(ends=rbind(c(0,0,0), c(0,10,0)), radius=1, col='green')
# Add lights in four corners of the bounding box
svg.bboxLight(x=rbind(c(1,1,1), c(-1,1,1), c(-1,-1,-1), c(1,-1,-1)))
# Close connection
svg.close()
## End(Not run)