feat(PDF):Add PDF viewer (#2730)

Display DICOM encapsulated PDF documents in a PDF viewer.
Addressed the remaining PR comments, and am merging this.
This commit is contained in:
Bill Wallace authored and GitHub committed 2022-04-04 09:48:14 -04:00
1 parent f3822f98a3
commit 82df3eac03
23 files changed
+376 -71

No files matched your search

+19 -1
View File
@@ -23,6 +23,11 @@ const dicomvideo = {
viewport: 'org.ohif.dicom-video.viewportModule.dicom-video',
}
const dicompdf = {
sopClassHandler: 'org.ohif.dicom-pdf.sopClassHandlerModule.dicom-pdf',
viewport: 'org.ohif.dicom-pdf.viewportModule.dicom-pdf',
}
export default function mode({ modeConfiguration }) {
return {
// TODO: We're using this as a route segment
@@ -96,6 +101,10 @@ export default function mode({ modeConfiguration }) {
namespace: dicomvideo.viewport,
displaySetsToDisplay: [dicomvideo.sopClassHandler],
},
{
namespace: dicompdf.viewport,
displaySetsToDisplay: [dicompdf.sopClassHandler],
},
],
},
};
@@ -108,9 +117,18 @@ export default function mode({ modeConfiguration }) {
'org.ohif.measurement-tracking',
'org.ohif.dicom-sr',
'org.ohif.dicom-video',
'org.ohif.dicom-pdf',
],
hangingProtocols: [ohif.hangingProtocols],
sopClassHandlers: [dicomvideo.sopClassHandler, ohif.sopClassHandler, dicomsr.sopClassHandler,],
// Order is important in sop class handlers when two handlers both use
// the same sop class under different situations. In that case, the more
// general handler needs to come last. For this case, the dicomvideo msut
// come first to remove video transfer syntax before ohif uses images
sopClassHandlers: [
dicomvideo.sopClassHandler,
ohif.sopClassHandler,
dicompdf.sopClassHandler,
dicomsr.sopClassHandler,],
hotkeys: [...hotkeys.defaults.hotkeyBindings],
};
}