Skip to content

fix(segmentation): Fix issue exposed by interpolationContourSegmentation example #2322

Merged
sedghi merged 1 commit into
cornerstonejs:mainfrom
jbocce:fix/contour-creation
Sep 11, 2025
Merged

fix(segmentation): Fix issue exposed by interpolationContourSegmentation example #2322
sedghi merged 1 commit into
cornerstonejs:mainfrom
jbocce:fix/contour-creation

Conversation

@jbocce
Copy link
Copy Markdown
Collaborator

@jbocce jbocce commented Sep 11, 2025

Context

Run the https://www.cornerstonejs.org/live-examples/interpolationcontoursegmentation example. Notice that an exception is thrown when clicking on an image to apply a segmentation to it.

Using git bisect I was able to determine that #2231 caused this issue.

Changes & Results

Initialize the active segment index to the first available segment if none is currently set.

Testing

Run the example. It should behave as expected.

Checklist

PR

  • My Pull Request title is descriptive, accurate and follows the
    semantic-release format and guidelines.

Code

  • My code has been well-documented (function documentation, inline comments,
    etc.)

Public Documentation Updates

  • The documentation page has been updated as necessary for any public API
    additions or removals.

Tested Environment

  • "OS: Windows 11
  • "Node version: 23.9.0
  • "Browser: Chrome 140.0.7339.81

@jbocce jbocce requested a review from sedghi September 11, 2025 15:40
@sedghi sedghi merged commit 2ac9f9a into cornerstonejs:main Sep 11, 2025
10 checks passed
@jbocce jbocce deleted the fix/contour-creation branch September 11, 2025 17:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants