Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

propertySetter

Obsolete functions to write HTML/Javascript code to control a WebGL display


Description

These functions write out HTML code to control WebGL displays based using the obsolete writeWebGL. Use playwidget and related functions instead.

Usage

propertySlider(setter = propertySetter,
             minS = NULL, maxS = NULL, step = 1, init = NULL, 
	     labels, 
	     id = basename(tempfile("input")), name = id,
	     outputid = paste0(id, "text"),
	     index = NULL,
	     ...) 
	     
propertySetter(values = NULL, entries, properties, objids, prefixes = "",
               param = seq_len(NROW(values)), interp = TRUE, digits = 7) 
               
par3dinterpSetter(fn, from, to, steps, subscene, omitConstant = TRUE, 
                  rename = character(), ...)

matrixSetter(fns, from, to, steps, subscene = currentSubscene3d(), 
             matrix = "userMatrix", omitConstant = TRUE, prefix = "", ...) 
             
vertexSetter(values, vertices = 1, attributes, objid, prefix = "",
	     param = seq_len(NROW(values)), interp = TRUE,
	     digits = 7)

Arguments

setter

A function to write Javascript code, or its output, or a list containing several of these.

minS, maxS, step, init

Slider values to be displayed. Reasonable defaults are used if missing.

labels

Labels to display for each slider value. The defaults are calculated using internal variables. If NULL, no labels will be shown.

id

The id of the input control that will be generated.

name

The name of the input control that will be generated.

outputid

The id of the output control that will display the slider value, or NULL for none.

index

The 1-based index of this slider: it controls the corresponding entry in an indexed setter such as matrixSetter.

...

Other parameters.

values

An array of values; rows correspond to slider positions. Alternatively, NULL; the generated function takes a single value or array of values and applies them directly.

entries, properties, objids, prefixes

Vectors describing the columns of values.

param

Parameter values corresponding to each row of values.

interp

Whether to interpolate values. If FALSE, the Javascript function will expect non-negative integer values. Ignored if values is NULL.

digits

How many significant digits to emit in the Javascript code.

fn

A function returned from par3dinterp.

from, to, steps

Values where fn should be evaluated.

subscene

Which subscene's properties should be modified?

omitConstant

If TRUE, do not set values that are constant across the range.

rename

A named character vector of names of Javascript properties to modify.

fns

A list containing functions returned from par3dinterp.

matrix

A character string giving the Javascript property name of the matrix to modify.

prefix

The prefix of the scene containing matrix.

vertices

A vector of vertex numbers (1-based) within an object.

attributes

A vector of attributes of a vertex, from c("x", "y", "z", "r", "g", "b", "a", "nx", "ny", "nz", "radius", "ox", "oy", "oz", "ts", "tt").

objid

The object containing the vertices to be modified.

Author(s)

Duncan Murdoch

See Also


rgl

3D Visualization Using OpenGL

v0.106.8
GPL
Authors
Duncan Murdoch [aut, cre], Daniel Adler [aut], Oleg Nenadic [ctb], Simon Urbanek [ctb], Ming Chen [ctb], Albrecht Gebhardt [ctb], Ben Bolker [ctb], Gabor Csardi [ctb], Adam Strzelecki [ctb], Alexander Senger [ctb], The R Core Team [ctb, cph], Dirk Eddelbuettel [ctb], The authors of Shiny [cph], The authors of knitr [cph], Jeroen Ooms [ctb], Yohann Demont [ctb], Joshua Ulrich [ctb], Xavier Fernandez i Marin [ctb], George Helffrich [ctb], Ivan Krylov [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.