Modal dialog for saving par3d settings

Share:

Description

This function opens a modal dialog to allow particular views of an rgl scene to be saved.

Usage

1
par3dsave(params = c("userMatrix", "scale", "zoom", "FOV"), times = FALSE, dev = rgl.cur())

Arguments

params

Which parameters to save

times

Should times be saved as well?

dev

Which rgl device to work with

Details

This opens a modal dialog box with Record and Quit buttons. Each time Record is clicked, a snapshot is taken of current par3d settings. When Quit is clicked, the dialog closes and the values are returned in a list.

If times == TRUE, then the times at which the views are recorded will also be saved, so that the play3d function will play back with the same timing.

Value

A list of the requested components. Each one will consist of a list of values that were current when the Record button was clicked. These are suitable to be passed directly to the par3dinterp function.

Author(s)

Duncan Murdoch

See Also

par3d, par3dinterp

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 

# Record a series of positions, and then play them back immediately
# at evenly spaced times, in an oscillating loop

play3d( par3dinterp( par3dsave() ) )

# As above, but preserve the click timings

play3d( par3dinterp( par3dsave(times=TRUE) ) )

## End(Not run)