Add measurement tools (distance, HU probe, ROI) to the viewer#31
Merged
Conversation
- Register Cornerstone LengthTool / ProbeTool / RectangleROITool and add toolbar buttons for distance (mm), HU-at-point, and rectangle ROI (HU + area). - setActiveMeasurementTool() hands the primary mouse button to the chosen measure tool and disables crosshair/pan while measuring; clearMeasurements() removes only measurement annotations, leaving the crosshair intact. - Recolor measurement annotations to cyan (resting) / white (selected) so they read cleanly over the colored organ masks instead of the default yellow/green. - Update the viewer smoke-test mock with the new exports.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds measurement tools to the case viewer:
Built on Cornerstone's standard
LengthTool/ProbeTool/RectangleROITool, added to the existing tool group alongside the crosshair/pan/zoom tools.How it works
setActiveMeasurementTool()hands the primary mouse button to the selected measure tool and disables crosshair/pan while measuring; clicking the tool again (or the crosshair button) returns to navigation.clearMeasurements()removes only measurement annotations, so the crosshair is preserved.Correctness
Testing
tsc -b) ✓