3D visualization device system
3D real-time rendering system.
# Low level rgl.* interface rgl.open(useNULL = rgl.useNULL()) # open new device rgl.close() # close current device rgl.cur() # returns active device ID rgl.dev.list() # returns all device IDs rgl.set(which, silent = FALSE) # set device as active rgl.quit() # shutdown rgl device system rgl.init(initValue = 0, onlyNULL = FALSE) # re-initialize rgl
- whether to open the
- device ID
- whether to suppress update of window titles
- value for internal use only
- only initialize the null (no display) device
rgl.quit() shuts down the rgl subsystem and all open devices,
detaches the package including the shared library and additional system libraries.
rgl.open() function attempts to open a new RGL window.
"rgl.antialias" option is set, it will be used to
select the requested antialiasing. (See
more description of antialiasing and an alternative way to set the
and similar functions.
rgl.open() fails (e.g. because X windows is not running, or its
DISPLAY variable is not set properly), then you can retry the initialization
rgl.init(). Do not do this when windows have
already been successfully opened: they will be orphaned, with no way to
remove them other than closing R. In fact, it's probably a good idea not to do this
at all: quitting R and restarting it is a better solution.
This package also includes a higher level interface which is described
in the r3d help topic. That interface is designed to act more like
classic 2D R graphics. We recommend that you avoid mixing
See the first example below to display the ChangeLog.
rgl.setare called for their side effects and return no useful value. Similarly
rgl.quitare not designed to return useful values; in fact, users shouldn't call them at all!
rgl.curreturns the currently active devices, or
0if none is active;
rgl.dev.listreturns a vector of all open devices. Both functions name the items according to the type of device:
nullfor a hidden null device,
wglfor a Windows device,
glXfor an X windows device, and
NSopenGLfor a Cocoa device on OSX.