-
Notifications
You must be signed in to change notification settings - Fork 327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(contour api): add api for contour rendering configuration #443
Conversation
✅ Deploy Preview for cornerstone-3d-docs ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some minor comments with regards to running some examples. Otherwise looks good.
}); | ||
|
||
addSliderToToolbar({ | ||
title: 'Change Segment 2 Thickness For left viewport', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
9bdb148
to
7021051
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Some minor comments.
packages/tools/src/tools/displayTools/Contour/addOrUpdateContourSets.ts
Outdated
Show resolved
Hide resolved
packages/tools/src/tools/displayTools/Contour/contourConfigCache.ts
Outdated
Show resolved
Hide resolved
@@ -123,17 +117,10 @@ function removeSegmentationRepresentation( | |||
*/ | |||
async function render( | |||
viewport: Types.IVolumeViewport, | |||
representation: ToolGroupSpecificRepresentation, | |||
representationConfig: ToolGroupSpecificRepresentation, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why was this renamed to config?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is was named incorrectly before
|
||
const newOutlineWithActive = newContourConfig.outlineWidthActive; | ||
|
||
if (cachedConfig.outlineWidthActive !== newOutlineWithActive) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a chance that cachedConfig
might be undefined
or null
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there shouldn't be since we add first, and that caches it, but I added the checks
const type = contour.getType(); | ||
|
||
// creating a point index list that defines a line | ||
const pointIndexes = pointList.map((_, i) => i + pointIndex); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider renaming i
to pointListIndex
or something.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Thanks for the updates.
Labelmap
vsContour
segmentation representationvisibility
(for all its contour sets), and per contour set:visibility
andthickness