new Opacity(app)
Opacity class.
Parameters:
Name | Type | Description |
---|---|---|
app | dwv. | The associated application. |
- Source
Example
// create the dwv app
var app = new dwv.App();
// initialise
app.init({
dataViewConfigs: {'*': [{divId: 'layerGroup0'}]},
tools: {Opacity: {}}
});
// activate tool
app.addEventListener('load', function () {
app.setTool('Opacity');
});
// load dicom data
app.loadURLs([
'https://raw.githubusercontent.com/ivmartel/dwv/master/tests/data/bbmri-53323851.dcm'
]);
Members
started :boolean
Interaction start flag.
Type:
- boolean
- Source
(inner) scrollWhell :dwv.tool.ScrollWheel
Scroll wheel handler.
Type:
- Source
Methods
activate(_bool)
Activate the tool.
Parameters:
Name | Type | Description |
---|---|---|
_bool | boolean | The flag to activate or not. |
- Source
init()
Initialise the tool.
- Source
keydown(event)
Handle key down event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The key down event. |
- Source
mousedown(event)
Handle mouse down event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The mouse down event. |
- Source
mousemove(event)
Handle mouse move event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The mouse move event. |
- Source
mouseout(event)
Handle mouse out event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The mouse out event. |
- Source
mouseup(_event)
Handle mouse up event.
Parameters:
Name | Type | Description |
---|---|---|
_event | object | The mouse up event. |
- Source
touchend(event)
Handle touch end event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The touch end event. |
- Source
touchmove(event)
Handle touch move event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The touch move event. |
- Source
touchstart(event)
Handle touch start event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The touch start event. |
- Source
wheel(event)
Handle mouse wheel event.
Parameters:
Name | Type | Description |
---|---|---|
event | object | The mouse wheel event. |
- Source