1.0.26 • Published 1 year ago

cornerstonetools-thresholdbrush v1.0.26

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

cornerstonetools-thresholdbrush

A threshold brush that draws pixels only within the specified threshold low and high range.

ezgif com-gif-maker

Notice how it only draws on the bone which is in a threshold range of 200 to 1000. and If I attempt to draw on other pixels outside of that range, nothing gets drawn.

Dependencies

Demo

Below is a live demo of the threshold brush tool, in the demo the threshold range is set to 200, 1000

LIVE DEMONSTRATION

Installation

$ npm i cornerstonetools-thresholdbrush

Example

import ThresholdBrush from "cornerstonetools-thresholdbrush";

cornerstoneTools.addToolForElement(element, ThresholdBrush, {configuration: {thresholdLow: 200 , thresholdHigh: 1000}});
cornerstoneTools.setToolActive("ThresholdBrush", { mouseButtonMask: 1 });

You can modify the threshold low an threshold high configuration on the fly like the following

let brushThreshold = cornerstoneTools.store.state.tools.filter(tool => tool.name == 'ThresholdBrush')[0].configuration
brushThreshold.thresholdLow = -29
brushThreshold.thresholdHigh = 150

Common thresholds to get you started

Left Psoas : -29, 150 Right Psoas : -29, 150 Muscle : -29, 150 Sub Fat : -190, -30 Vis Fat : -190, -30 Bone : 200, 1000

LICENSE

MIT

1.0.26

1 year ago

1.0.25

1 year ago

1.0.24

1 year ago

1.0.23

1 year ago

1.0.22

1 year ago

1.0.21

1 year ago

1.0.20

1 year ago

1.0.19

1 year ago

1.0.18

1 year ago

1.0.17

1 year ago

1.0.16

1 year ago

1.0.15

1 year ago

1.0.13

1 year ago

1.0.12

1 year ago

1.0.11

1 year ago

1.0.10

1 year ago

1.0.9

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago