Display
Class representing the main render area.
Extends
Methods
| Method | Description |
|---|---|
| setSize() | Sets the size of the render area in pixels. |
| render() | Perform rendering of the Display and all its Views. |
| layouter() | Returns the DisplayAutoLayouter used to perform automatic layouting of the views. |
| main2dView() | Returns the SliceView for showing 2D data. |
| mainAxialView() | Returns the axial SliceView for showing 3D data. |
| mainCoronalView() | Returns the coronal SliceView for showing 3D data. |
| mainSagittalView() | Returns the sagittal SliceView for showing 3D data. |
| main3dView() | Returns the VolumeView for showing 3D data. |
| viewGroup() | Returns the view group that contains all views. |
| mainViewOverlays() | Returns the RadiologyViewOverlays instance enabling you to easily create and maintain common ViewOverlays. |
| sliceIndicator() | Returns the SliceIndicator of this display. |
| handleMouseDown() | Handle a mousedown event. |
| handleMouseUp() | Handle a mouseup event. |
| handleDoubleClick() | Handle a dblclick event. |
| handleMouseMove() | Handle a mousemove event. |
| handleMouseWheel() | Handle a wheel event. |
| handleTouchPointerDown() | Handle a pointerdown event of pointerType touch |
| handleTouchPointerMove() | Handle a pointermove event of pointerType touch |
| handleTouchPointerUp() | Handle a pointerup event of pointerType touch |
| handleTouchPointerCancel() | Handle a pointercancel event of pointerType touch |
| handleLongPress() | Handle a long press event |
| handleTouchStart() | |
| handleTouchMove() | |
| handleTouchEnd() | |
| handleContextMenu() | Handle a contextmenu event. |
| onUpdateRequested() | Fires when a render is requested. |
| setBackgroundColor() | Set the optional background color of the rendering area. |
Inherited from ClassHandle
| Method | Description |
|---|---|
| isAliasOf() | Returns true if this handle and other alias the same underlying C++ object. |
| delete() | Releases this JavaScript handle. |
| deleteLater() | Schedules this handle for deferred deletion and returns this handle. |
| isDeleted() | Returns true if this handle has already been deleted. |
| [dispose]() | Releases this handle when the enclosing scope exits, so a handle can be declared with using instead of calling delete() later manually. |
| clone() | Returns a new JavaScript handle aliasing the same underlying C++ object. |
setSize()
Sets the size of the render area in pixels.
Parameters
| Parameter | Type |
|---|---|
width | number |
height | number |
Returns
void
render()
Perform rendering of the Display and all its Views.
Returns
void
layouter()
Returns the DisplayAutoLayouter used to perform automatic layouting of the views.
Returns
main2dView()
Returns the SliceView for showing 2D data.
Returns
mainAxialView()
Returns the axial SliceView for showing 3D data.
Returns
mainCoronalView()
Returns the coronal SliceView for showing 3D data.
Returns
mainSagittalView()
Returns the sagittal SliceView for showing 3D data.
Returns
main3dView()
Returns the VolumeView for showing 3D data.
Returns
viewGroup()
Returns the view group that contains all views.
Returns
mainViewOverlays()
Returns the RadiologyViewOverlays instance enabling you to easily create and maintain common ViewOverlays.
Returns
sliceIndicator()
Returns the SliceIndicator of this display.
Returns
handleMouseDown()
Handle a mousedown event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | MouseEvent | https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent |
Returns
handleMouseUp()
Handle a mouseup event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | MouseEvent | https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent |
Returns
handleDoubleClick()
Handle a dblclick event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | MouseEvent | https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent |
Returns
handleMouseMove()
Handle a mousemove event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | MouseEvent | https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent |
Returns
handleMouseWheel()
Handle a wheel event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | WheelEvent | https://developer.mozilla.org/en-US/docs/Web/API/Element/wheel_event |
Returns
handleTouchPointerDown()
Handle a pointerdown event of pointerType touch
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
handleTouchPointerMove()
Handle a pointermove event of pointerType touch
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
handleTouchPointerUp()
Handle a pointerup event of pointerType touch
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
handleTouchPointerCancel()
Handle a pointercancel event of pointerType touch
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
handleLongPress()
Handle a long press event
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
handleTouchStart()
Parameters
| Parameter | Type | Description |
|---|---|---|
event | TouchEvent | https://developer.mozilla.org/en-US/docs/Web/API/TouchEvent |
Returns
Deprecated
- Use handlePointerTouchEvent instead
Handle a
touchstartevent.
handleTouchMove()
Parameters
| Parameter | Type | Description |
|---|---|---|
event | TouchEvent | https://developer.mozilla.org/en-US/docs/Web/API/TouchEvent |
Returns
Deprecated
- Use handlePointerTouchEvent instead
Handle a
touchmoveevent.
handleTouchEnd()
Parameters
| Parameter | Type | Description |
|---|---|---|
event | TouchEvent | https://developer.mozilla.org/en-US/docs/Web/API/TouchEvent |
Returns
Deprecated
- Use handlePointerTouchEvent instead
Handle a
touchendevent.
handleContextMenu()
Handle a contextmenu event.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | PointerEvent | https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent |
Returns
onUpdateRequested()
Fires when a render is requested.
Parameters
| Parameter | Type |
|---|---|
callback | () => void |
Returns
Unsubscribe function.
() => void
setBackgroundColor()
Set the optional background color of the rendering area.
Parameters
| Parameter | Type | Description |
|---|---|---|
color? | vec3 | The new background color. Omitting the parameter causes the display to not clear the color buffer of the rendering area. Note that individual views might still clear their own viewport. |
Returns
void