feat(Thumbnail): Display set messages support & displaying of series inconsistencies in the thumbnail (#3499)

Co-authored-by: Igor Octaviano <igoroctaviano@gmail.com>
This commit is contained in:
rodrigobasilio2022andIgor Octaviano authored and GitHub committed 2023-08-11 19:16:25 -03:00
1 parent aedb9d1576
commit 5302e5b62b
31 files changed
+1126 -12

No files matched your search

@@ -0,0 +1,32 @@
import {
hasPixelMeasurements,
hasOrientation,
hasPosition,
} from '@ohif/core/src/utils/isDisplaySetReconstructable';
import { DisplaySetMessage, DisplaySetMessageList } from '@ohif/core';
/**
* Check various multi frame issues. It calls OHIF core functions
* @param {*} multiFrameInstance
* @param {*} warnings
*/
export default function checkMultiFrame(
multiFrameInstance,
messages: DisplaySetMessageList
): void {
if (!hasPixelMeasurements(multiFrameInstance)) {
messages.addMessage(
DisplaySetMessage.CODES.MULTIFRAME_NO_PIXEL_MEASUREMENTS
);
}
if (!hasOrientation(multiFrameInstance)) {
messages.addMessage(DisplaySetMessage.CODES.MULTIFRAME_NO_ORIENTATION);
}
if (!hasPosition(multiFrameInstance)) {
messages.addMessage(
DisplaySetMessage.CODES.MULTIFRAME_NO_POSITION_INFORMATION
);
}
}