NGL@0.10.4 Home Manual Reference Source GalleryRepository
import MouseActions from 'ngl/src/controls/mouse-actions.js'
public class | source

MouseActions

Mouse actions provided as static methods

Static Method Summary

Static Public Methods
public static

Move near clipping plane based on scroll-delta

public static

focusScroll(stage: Stage, delta: Number): undefined

Move focus planes based on scroll-delta

public static

Change isolevel of volume surfaces based on scroll-delta

public static

movePick(stage: Stage, pickingProxy: PickingProxy): undefined

Move picked element to the center of the screen

public static

Pan picked component based on mouse coordinate changes

public static

panDrag(stage: Stage, dx: Number, dy: Number): undefined

Pan scene based on mouse coordinate changes

public static

Rotate picked component based on mouse coordinate changes

public static

rotateDrag(stage: Stage, dx: Number, dy: Number): undefined

Rotate scene based on mouse coordinate changes

public static

tooltipPick(stage: Stage, pickingProxy: PickingProxy): undefined

Show tooltip with information of picked element

public static

zoomDrag(stage: Stage, dx: Number, dy: Number): undefined

Zoom scene based on mouse coordinate changes

public static

Zoom scene based on mouse coordinate changes and move focus planes based on camera position (zoom)

public static

zoomScroll(stage: Stage, delta: Number): undefined

Zoom scene based on scroll-delta

Static Public Methods

public static clipNearScroll(stage: Stage, delta: Number): undefined source

Move near clipping plane based on scroll-delta

Params:

NameTypeAttributeDescription
stage Stage

the stage

delta Number

amount to move clipping plane

Return:

undefined

public static focusScroll(stage: Stage, delta: Number): undefined source

Move focus planes based on scroll-delta

Params:

NameTypeAttributeDescription
stage Stage

the stage

delta Number

amount to move focus planes

Return:

undefined

public static isolevelScroll(stage: Stage, delta: Number): undefined source

Change isolevel of volume surfaces based on scroll-delta

Params:

NameTypeAttributeDescription
stage Stage

the stage

delta Number

amount to change isolevel

Return:

undefined

public static movePick(stage: Stage, pickingProxy: PickingProxy): undefined source

Move picked element to the center of the screen

Params:

NameTypeAttributeDescription
stage Stage

the stage

pickingProxy PickingProxy

the picking data object

Return:

undefined

public static panComponentDrag(stage: Stage, dx: Number, dy: Number): undefined source

Pan picked component based on mouse coordinate changes

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to pan in x direction

dy Number

amount to pan in y direction

Return:

undefined

public static panDrag(stage: Stage, dx: Number, dy: Number): undefined source

Pan scene based on mouse coordinate changes

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to pan in x direction

dy Number

amount to pan in y direction

Return:

undefined

public static rotateComponentDrag(stage: Stage, dx: Number, dy: Number): undefined source

Rotate picked component based on mouse coordinate changes

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to rotate in x direction

dy Number

amount to rotate in y direction

Return:

undefined

public static rotateDrag(stage: Stage, dx: Number, dy: Number): undefined source

Rotate scene based on mouse coordinate changes

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to rotate in x direction

dy Number

amount to rotate in y direction

Return:

undefined

public static tooltipPick(stage: Stage, pickingProxy: PickingProxy): undefined source

Show tooltip with information of picked element

Params:

NameTypeAttributeDescription
stage Stage

the stage

pickingProxy PickingProxy

the picking data object

Return:

undefined

public static zoomDrag(stage: Stage, dx: Number, dy: Number): undefined source

Zoom scene based on mouse coordinate changes

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to zoom

dy Number

amount to zoom

Return:

undefined

public static zoomFocusDrag(stage: Stage, dx: Number, dy: Number): undefined source

Zoom scene based on mouse coordinate changes and move focus planes based on camera position (zoom)

Params:

NameTypeAttributeDescription
stage Stage

the stage

dx Number

amount to zoom

dy Number

amount to zoom

Return:

undefined

public static zoomScroll(stage: Stage, delta: Number): undefined source

Zoom scene based on scroll-delta

Params:

NameTypeAttributeDescription
stage Stage

the stage

delta Number

amount to zoom

Return:

undefined