Skip to content

VolumeController ​

Introduction ​

vtkVolumeController is a DOM overlay providing interactive control over a volume actor: color map preset, shading, sample distance, edge gradient opacity and a piecewise gaussian editor for the scalar opacity.

Methods ​

extend ​

Method used to decorate a given object (publicAPI+model) with vtkVolumeController characteristics.

ArgumentTypeRequiredDescription
publicAPIYesobject on which methods will be bounds (public)
modelYesobject on which data structure will be bounds (protected)
initialValuesIVolumeControllerInitialValuesNo(default: {})

getWidget ​

The embedded piecewise gaussian widget used to edit the scalar opacity.

newInstance ​

Method used to create a new instance of vtkVolumeController.

ArgumentTypeRequiredDescription
initialValuesIVolumeControllerInitialValuesNofor pre-setting some of its content

render ​

Render the embedded piecewise function editor.

setContainer ​

Attach the controller to the given DOM element, detaching it from any previously set one.

ArgumentTypeRequiredDescription
elYes

setRescaleColorMap ​

When true, the color transfer function mapping range follows the opacity range selected in the piecewise function editor.

ArgumentTypeRequiredDescription
valueBooleanYes

setSize ​

Resize the embedded piecewise function editor.

ArgumentTypeRequiredDescription
widthNumberYes
heightNumberYes

setupContent ​

Build the controller DOM content and wire it to the given volume actor.

ArgumentTypeRequiredDescription
renderWindowvtkRenderWindowYes
actorvtkVolumeYes
isBackgroundDarkBooleanYesselects the light or dark widget styling
useShadowString or NumberNo(default: '1')
presetNameStringNo(default: 'erdc_rainbow_bright')

toggleVisibility ​

Show or hide everything but the toggle button.