VRView

VRView

A class representing a Volume Rendering scene

Constructor

new VRView(element)

Source:

Create a volume rendering scene

Parameters:
Name Type Description
element HTMLElement

the target html element to render the scene

Classes

VRView

Members

blurOnInteraction :bool

Source:

Toggle blurring on interaction (Increase performance)

Type:
  • bool

cropWidget :bool

Source:

Crop widget on / off

Type:
  • bool

edgeEnhancement

Source:

Toggle edge enhancement

lut :String

Source:

Set colormap and opacity function
lutName - as in presets list

Type:
  • String

presetsList :Array

Source:

Presets

Type:
  • Array

rangeLUT :Array

Source:

Set range to apply lut !!! WIP

Type:
  • Array

rescaleLUT :bool

Source:

Flag to set lut rescaling on opacity range

Type:
  • bool

resolution :Number

Source:

raysDistance

Type:
  • Number

widgetElement :HTMLelement

Source:

PGwidgetElement (set null to hide)

Type:
  • HTMLelement

wwwl :Array

Source:

wwwl

Type:
  • Array

Methods

_initCropWidget()

Source:

Setup crop widget

_initPicker()

Source:

initPicker

addSurface()

Source:

Add surfaces to be rendered

Parameters:
Type Description
Object

{buffer: bufferarray, color: [r,g,b], label: string}

destroy()

Source:

Destroy webgl content and release listeners

getLutList() → {Array}

Source:

Get vtk LUTs list

Returns:
  • Lut list as array of strings
Type
Array

resetMeasurementState(measurementState)

Source:

Reset measurement state to default

Parameters:
Name Type Description
measurementState *

resetView()

Source:

Reset view

resize()

Source:

on resize callback

setImage(image)

Source:

Set the image to be rendered

Parameters:
Name Type Description
image ArrayBuffer

The image content data as buffer array

setSurfaceVisibility(label, toggle)

Source:

Toggle surface visibility on/off

Parameters:
Name Type Description
label String

The string that identifies the surface

toggle Boolean

setTool(toolName, options, measurementState)

Source:

Set active tool
("Length/Angle", {mouseButtonMask:1}, measurementState)

Parameters:
Name Type Description
toolName *
options *
measurementState *

updateSurface(label, buffer)

Source:

Update surface buffer
TODO maybe there is a more efficient way

Parameters:
Name Type Description
label String

The string that identifies the surface

buffer ArrayBuffer