fix: remaining bugs for MPR and toolbar icon colors (#3026)

* feat: warn for overlapping segments

* fix: typo

* refactor mpr toggle and stack sync

* fix: wip for more general mpr

* fix: tool groups for mpr

* fix: changing of viewport id

* fix: viewport Id for the seg viewports

* fix

* update cornerstone version
This commit is contained in:
Alireza authored and GitHub committed 2022-11-21 10:44:19 -05:00
1 parent 6db4d7a917
commit 87eab39768
27 files changed
+726 -384

No files matched your search

@@ -590,6 +590,8 @@ class SegmentationService {
// Note: ideally we could use the TypedArray set method, but since each
// slice can have multiple segments, we need to loop over each slice and
// set the segment value for each segment.
let overlappingSegments = false;
const _segmentInfoUpdate = (segmentInfo, segmentIndex) => {
const { pixelData: segPixelData } = segmentInfo;
@@ -636,6 +638,10 @@ class SegmentationService {
i++, j++
) {
if (functionGroupPixelData[j] !== 0) {
if (derivedVolumeScalarData[i] !== 0) {
overlappingSegments = true;
}
derivedVolumeScalarData[i] = segmentIndex;
// centroid calculations
@@ -716,6 +722,7 @@ class SegmentationService {
this._broadcastEvent(EVENTS.SEGMENTATION_PIXEL_DATA_CREATED, {
segmentationId,
segDisplaySet,
overlappingSegments,
});
return this.addOrUpdateSegmentation(segmentationSchema, suppressEvents);