fix(WindowLevelRegionTool): make region WL sampling image-space invariant - #2895
fix(WindowLevelRegionTool): make region WL sampling image-space invariant#2895atehrani-statrad wants to merge 3 commits into
Conversation
…-dependency fix(WindowLevelRegionTool): make region WL sampling image-space invariant
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review. 📝 WalkthroughWalkthroughThe window-level region tool now calculates ROI bounds in image coordinates. Volume, stack, and generic viewport extractors provide ChangesWindow-level region coordinate flow
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: ⚪ Minimal · up to The window-level region tool now samples the same image pixels regardless of viewport resizing while preserving existing unsupported-view behavior. No actionable merge-blocking risk remains beyond normal checks and review. Suggested reviewers: 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Context
This PR is to address and fix issue #2423
Changes & Results
WindowLevelRegionTool was deriving ROI extents in canvas space, so resizing the viewport changed sampled pixels and produced different WW/WL for the same visual region. This update makes ROI sampling image-space invariant while preserving existing no-backing-image behavior for unsupported native reformatted/oblique slices.
Testing
Checklist
PR
semantic-release format and guidelines.
Code
etc.)
Public Documentation Updates
additions or removals.
Tested Environment
Summary by CodeRabbit
Bug Fixes
Tests