@ohif/app 3.8.0-beta.6 → 3.8.0-beta.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{220.bundle.f7e1c96c94245e70f2be.js → 109.bundle.b4fee2a22b622839baf5.js} +4466 -3715
- package/dist/{471.bundle.b3d77b83b1593c09a504.js → 121.bundle.ed23e7752a11005322e6.js} +47 -51
- package/dist/{19.bundle.f6ac71d29001b0db0ec0.js → 155.bundle.a089b4e1dd8a13064c21.js} +198 -207
- package/dist/{687.bundle.f87fb1a36ef1ca951690.js → 164.bundle.6f0b21868890158eda40.js} +22 -38
- package/dist/17dd54813d5acc10bf8f.wasm +0 -0
- package/dist/{506.bundle.06f5c5620d0088ec0102.js → 188.bundle.903a17abf035c26e672f.js} +23 -28
- package/dist/20fc4c659b85ccd2a9c0.wasm +0 -0
- package/dist/214.bundle.7f5beb123035a163bf85.js +122755 -0
- package/dist/{126.bundle.cefdf26c03a5ab8d60c8.js → 250.bundle.13a1f5d003a00c2b8694.js} +63 -69
- package/dist/{236.bundle.3148dc4715c254801727.js → 270.bundle.4e3cd0e72bbff21f9596.js} +156 -178
- package/dist/290.bundle.fdf51412462b919e2772.js +8883 -0
- package/dist/{451.bundle.9fd36f52ff69594f0669.js → 295.bundle.462f3328c716cbe6c613.js} +45 -59
- package/dist/{125.bundle.253395f320b72180da63.js → 297.bundle.81d63bb0b66d63df6d86.js} +7 -8
- package/dist/{957.bundle.9ea4506963ef8b2d84ba.js → 307.bundle.6e884b1c8766c69560bd.js} +14569 -27570
- package/dist/{613.bundle.a0eee4dc2d2764c2f7cd.js → 317.bundle.9d9acdf28d8dfd3ab39e.js} +83 -57
- package/dist/{788.bundle.af903bf0598f0ad618e3.js → 339.bundle.d514a9189b0bbdedac75.js} +190 -239
- package/dist/342.bundle.8f20bc9a1fa5fed22d2d.js +51866 -0
- package/dist/457.bundle.64785b282dc8c9b64c92.js +30200 -0
- package/dist/{221.bundle.3f5f700b4c1ee8b1ce94.js → 50.bundle.5f1ddd2697906f8bde6b.js} +199 -189
- package/dist/{886.bundle.d5116d9b8ea4964b68a0.js → 530.bundle.ce13c30b93a28cc85098.js} +40 -44
- package/dist/{250.bundle.8084960e3318cda37317.js → 544.bundle.3f48123a58d3bdc052f5.js} +39 -44
- package/dist/{663.bundle.e3539f14edf9214e07eb.js → 559.bundle.7426bb86db4352f1c401.js} +149 -141
- package/dist/{410.bundle.5e16274b1082de6e127e.js → 594.bundle.9eb2863c4d3fbe4120c5.js} +31 -35
- package/dist/{774.bundle.4b2dc46a35012b898e1a.js → 644.bundle.1e77691d2eeb96a423b0.js} +1852 -8945
- package/dist/{82.bundle.ae82f6434056c8d79fec.js → 68.bundle.7ca79597088a0784c4ee.js} +313 -324
- package/dist/{342.bundle.e485b92bd6d91bb7cc04.js → 704.bundle.9ecbe7b05ea278ef6ba8.js} +1128 -737
- package/dist/{359.bundle.dedb5b782335939bdc52.js → 724.bundle.46d9ce1eb6867cdd81c0.js} +34 -37
- package/dist/{757.bundle.ec8301d8e70d2b990f65.js → 726.bundle.2bdb443d1b5620d74e6e.js} +512 -879
- package/dist/{530.bundle.a03b6f942ace3e1baa1e.js → 835.bundle.15aff0b7433bb0dd6d6d.js} +37 -30
- package/dist/{822.bundle.891f2e57b1b7bc2f4cb4.js → 862.bundle.d20d6b2d29fd89bf2f83.js} +27 -29
- package/dist/{181.bundle.2ddc6f90740895a3949c.js → 889.bundle.d77bbd1805d4f0bd0565.js} +135 -107
- package/dist/{181.css → 889.css} +1 -1
- package/dist/{281.bundle.e4c37762343dc03e4fa0.js → 905.bundle.53a0daccf13d3e134ab9.js} +29 -31
- package/dist/{814.bundle.98e400df965d000d78e6.js → 907.bundle.b1f7dffcc6187de1b7ad.js} +16 -18
- package/dist/{417.bundle.af0a207c29b109f84159.js → 931.bundle.d270a1fda9a2836c3cc5.js} +26 -26
- package/dist/{686.bundle.dccef1f36e4bc79bcc48.js → 939.bundle.84ee0b844023d924a22b.js} +7 -8
- package/dist/{12.bundle.75c761bd89ad782675c8.js → 961.bundle.54abd182a494b2e1d8ec.js} +16 -18
- package/dist/{776.bundle.08eb381dc3d06708eb0f.js → 963.bundle.8110049ad01d956455a2.js} +1629 -845
- package/dist/app.bundle.css +11 -11
- package/dist/{app.bundle.eeb94536f34535b1153f.js → app.bundle.f783ca295d5aa9042c31.js} +142266 -61058
- package/dist/cornerstoneDICOMImageLoader.min.js +1 -1
- package/dist/cornerstoneDICOMImageLoader.min.js.map +1 -1
- package/dist/{dicom-microscopy-viewer.bundle.2c146384eb9466d02ff8.js → dicom-microscopy-viewer.bundle.d3a56dc9f62df5e11019.js} +3 -3
- package/dist/index.html +1 -1
- package/dist/{index.worker.e62ecca63f1a2e124230.worker.js → index.worker.64c896c4316fcd506666.worker.js} +2 -2
- package/dist/index.worker.64c896c4316fcd506666.worker.js.map +1 -0
- package/dist/polySeg.bundle.cffa671e87c4c9110149.js +252 -0
- package/dist/serve.json +12 -0
- package/dist/sw.js +1 -1
- package/package.json +25 -22
- package/dist/202.bundle.d3490836f71e001dd30f.js +0 -6336
- package/dist/23.bundle.e008ad788170f2ed5569.js +0 -900
- package/dist/604.bundle.a51f83e64004bca5f497.js +0 -1848
- package/dist/743.bundle.489f7df3a089d4d374e1.js +0 -78007
- package/dist/75788f12450d4c5ed494.wasm +0 -0
- package/dist/775.bundle.2285e7e0e67878948c0d.js +0 -1009
- package/dist/index.worker.e62ecca63f1a2e124230.worker.js.map +0 -1
- /package/dist/{19.css → 155.css} +0 -0
- /package/dist/{579.css → 481.css} +0 -0
- /package/dist/{221.css → 50.css} +0 -0
- /package/dist/{250.css → 544.css} +0 -0
- /package/dist/{776.css → 963.css} +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
(globalThis["webpackChunk"] = globalThis["webpackChunk"] || []).push([[559],{
|
|
2
3
|
|
|
3
|
-
/***/
|
|
4
|
+
/***/ 89559:
|
|
4
5
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
5
6
|
|
|
6
|
-
"use strict";
|
|
7
7
|
// ESM COMPAT FLAG
|
|
8
8
|
__webpack_require__.r(__webpack_exports__);
|
|
9
9
|
|
|
@@ -11,30 +11,30 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
11
11
|
__webpack_require__.d(__webpack_exports__, {
|
|
12
12
|
createReferencedImageDisplaySet: () => (/* reexport */ utils_createReferencedImageDisplaySet),
|
|
13
13
|
"default": () => (/* binding */ cornerstone_dicom_sr_src),
|
|
14
|
-
hydrateStructuredReport: () => (/* reexport */ hydrateStructuredReport/* default */.
|
|
14
|
+
hydrateStructuredReport: () => (/* reexport */ hydrateStructuredReport/* default */.A),
|
|
15
15
|
srProtocol: () => (/* reexport */ srProtocol)
|
|
16
16
|
});
|
|
17
17
|
|
|
18
18
|
// EXTERNAL MODULE: ../../../node_modules/react/index.js
|
|
19
|
-
var react = __webpack_require__(
|
|
19
|
+
var react = __webpack_require__(41766);
|
|
20
20
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/package.json
|
|
21
|
-
const package_namespaceObject = JSON.parse('{"
|
|
21
|
+
const package_namespaceObject = /*#__PURE__*/JSON.parse('{"UU":"@ohif/extension-cornerstone-dicom-sr"}');
|
|
22
22
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/id.js
|
|
23
23
|
|
|
24
|
-
const id = package_namespaceObject.
|
|
24
|
+
const id = package_namespaceObject.UU;
|
|
25
25
|
const SOPClassHandlerName = 'dicom-sr';
|
|
26
26
|
const SOPClassHandlerId = `${id}.sopClassHandlerModule.${SOPClassHandlerName}`;
|
|
27
27
|
|
|
28
|
-
// EXTERNAL MODULE: ../../core/src/index.ts +
|
|
29
|
-
var src = __webpack_require__(
|
|
28
|
+
// EXTERNAL MODULE: ../../core/src/index.ts + 66 modules
|
|
29
|
+
var src = __webpack_require__(14283);
|
|
30
30
|
// EXTERNAL MODULE: ../../../node_modules/gl-matrix/esm/index.js + 10 modules
|
|
31
|
-
var esm = __webpack_require__(
|
|
32
|
-
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/tools/dist/esm/index.js +
|
|
33
|
-
var dist_esm = __webpack_require__(
|
|
34
|
-
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/core/dist/esm/index.js +
|
|
35
|
-
var core_dist_esm = __webpack_require__(
|
|
31
|
+
var esm = __webpack_require__(83636);
|
|
32
|
+
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/tools/dist/esm/index.js + 14 modules
|
|
33
|
+
var dist_esm = __webpack_require__(72980);
|
|
34
|
+
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/core/dist/esm/index.js + 382 modules
|
|
35
|
+
var core_dist_esm = __webpack_require__(39526);
|
|
36
36
|
// EXTERNAL MODULE: ../../../extensions/cornerstone-dicom-sr/src/tools/modules/dicomSRModule.js
|
|
37
|
-
var dicomSRModule = __webpack_require__(
|
|
37
|
+
var dicomSRModule = __webpack_require__(74334);
|
|
38
38
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/constants/scoordTypes.js
|
|
39
39
|
/* harmony default export */ const scoordTypes = ({
|
|
40
40
|
POINT: 'POINT',
|
|
@@ -49,11 +49,9 @@ var dicomSRModule = __webpack_require__(64035);
|
|
|
49
49
|
|
|
50
50
|
|
|
51
51
|
class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
52
|
-
constructor(
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
configuration: {}
|
|
56
|
-
};
|
|
52
|
+
constructor(toolProps = {}, defaultToolProps = {
|
|
53
|
+
configuration: {}
|
|
54
|
+
}) {
|
|
57
55
|
super(toolProps, defaultToolProps);
|
|
58
56
|
// This tool should not inherit from AnnotationTool and we should not need
|
|
59
57
|
// to add the following lines.
|
|
@@ -76,7 +74,7 @@ class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
|
76
74
|
if (!annotations?.length) {
|
|
77
75
|
return;
|
|
78
76
|
}
|
|
79
|
-
const trackingUniqueIdentifiersForElement = (0,dicomSRModule/* getTrackingUniqueIdentifiersForElement */.
|
|
77
|
+
const trackingUniqueIdentifiersForElement = (0,dicomSRModule/* getTrackingUniqueIdentifiersForElement */.eF)(element);
|
|
80
78
|
const {
|
|
81
79
|
activeIndex,
|
|
82
80
|
trackingUniqueIdentifiers
|
|
@@ -173,7 +171,6 @@ class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
|
173
171
|
});
|
|
174
172
|
return allCanvasCoordinates; // used for drawing textBox
|
|
175
173
|
}
|
|
176
|
-
|
|
177
174
|
renderMultipoint(svgDrawingHelper, viewport, renderableData, annotationUID, referencedImageId, options) {
|
|
178
175
|
let canvasCoordinates;
|
|
179
176
|
renderableData.map((data, index) => {
|
|
@@ -216,7 +213,6 @@ class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
|
216
213
|
});
|
|
217
214
|
return canvasCoordinates; // used for drawing textBox
|
|
218
215
|
}
|
|
219
|
-
|
|
220
216
|
renderEllipse(svgDrawingHelper, viewport, renderableData, annotationUID, referencedImageId, options) {
|
|
221
217
|
let canvasCoordinates;
|
|
222
218
|
renderableData.map((data, index) => {
|
|
@@ -242,8 +238,7 @@ class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
|
242
238
|
});
|
|
243
239
|
return canvasCoordinates;
|
|
244
240
|
}
|
|
245
|
-
renderTextBox(svgDrawingHelper, viewport, canvasCoordinates, canvasCoordinatesAdapter, annotation, styleSpecifier) {
|
|
246
|
-
let options = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : {};
|
|
241
|
+
renderTextBox(svgDrawingHelper, viewport, canvasCoordinates, canvasCoordinatesAdapter, annotation, styleSpecifier, options = {}) {
|
|
247
242
|
if (!canvasCoordinates || !annotation) {
|
|
248
243
|
return;
|
|
249
244
|
}
|
|
@@ -264,7 +259,9 @@ class DICOMSRDisplayTool extends dist_esm.AnnotationTool {
|
|
|
264
259
|
}
|
|
265
260
|
const textLines = this._getTextBoxLinesFromLabels(label);
|
|
266
261
|
const canvasTextBoxCoords = dist_esm.utilities.drawing.getTextBoxCoordsCanvas(adaptedCanvasCoordinates);
|
|
267
|
-
annotation.data
|
|
262
|
+
if (!annotation.data?.handles?.textBox?.worldPosition) {
|
|
263
|
+
annotation.data.handles.textBox.worldPosition = viewport.canvasToWorld(canvasTextBoxCoords);
|
|
264
|
+
}
|
|
268
265
|
const textBoxPosition = viewport.worldToCanvas(annotation.data.handles.textBox.worldPosition);
|
|
269
266
|
const textBoxUID = '1';
|
|
270
267
|
const textBoxOptions = this.getLinkedTextBoxStyle(styleSpecifier, annotation);
|
|
@@ -360,7 +357,7 @@ function addMeasurement(measurement, imageId, displaySetInstanceUID) {
|
|
|
360
357
|
data: {
|
|
361
358
|
label: measurement.labels,
|
|
362
359
|
handles: {
|
|
363
|
-
textBox: {}
|
|
360
|
+
textBox: measurement.textBox ?? {}
|
|
364
361
|
},
|
|
365
362
|
cachedStats: {
|
|
366
363
|
TrackingUniqueIdentifier: measurementData.TrackingUniqueIdentifier,
|
|
@@ -407,7 +404,7 @@ function _getRenderableData(GraphicType, GraphicData, imageId, TrackingIdentifie
|
|
|
407
404
|
// here we reshape the data for that purpose.
|
|
408
405
|
const center = pointsWorld[0];
|
|
409
406
|
const onPerimeter = pointsWorld[1];
|
|
410
|
-
const radius = esm/* vec3.distance */.
|
|
407
|
+
const radius = esm/* vec3.distance */.eR.distance(center, onPerimeter);
|
|
411
408
|
const imagePlaneModule = core_dist_esm.metaData.get('imagePlaneModule', imageId);
|
|
412
409
|
if (!imagePlaneModule) {
|
|
413
410
|
throw new Error('No imagePlaneModule found');
|
|
@@ -420,16 +417,16 @@ function _getRenderableData(GraphicType, GraphicData, imageId, TrackingIdentifie
|
|
|
420
417
|
// we need to get major/minor axis (which are both the same size major = minor)
|
|
421
418
|
|
|
422
419
|
// first axisStart
|
|
423
|
-
const firstAxisStart = esm/* vec3.create */.
|
|
424
|
-
esm/* vec3.scaleAndAdd */.
|
|
425
|
-
const firstAxisEnd = esm/* vec3.create */.
|
|
426
|
-
esm/* vec3.scaleAndAdd */.
|
|
420
|
+
const firstAxisStart = esm/* vec3.create */.eR.create();
|
|
421
|
+
esm/* vec3.scaleAndAdd */.eR.scaleAndAdd(firstAxisStart, center, columnCosines, radius);
|
|
422
|
+
const firstAxisEnd = esm/* vec3.create */.eR.create();
|
|
423
|
+
esm/* vec3.scaleAndAdd */.eR.scaleAndAdd(firstAxisEnd, center, columnCosines, -radius);
|
|
427
424
|
|
|
428
425
|
// second axisStart
|
|
429
|
-
const secondAxisStart = esm/* vec3.create */.
|
|
430
|
-
esm/* vec3.scaleAndAdd */.
|
|
431
|
-
const secondAxisEnd = esm/* vec3.create */.
|
|
432
|
-
esm/* vec3.scaleAndAdd */.
|
|
426
|
+
const secondAxisStart = esm/* vec3.create */.eR.create();
|
|
427
|
+
esm/* vec3.scaleAndAdd */.eR.scaleAndAdd(secondAxisStart, center, rowCosines, radius);
|
|
428
|
+
const secondAxisEnd = esm/* vec3.create */.eR.create();
|
|
429
|
+
esm/* vec3.scaleAndAdd */.eR.scaleAndAdd(secondAxisEnd, center, rowCosines, -radius);
|
|
433
430
|
renderableData = [firstAxisStart, firstAxisEnd, secondAxisStart, secondAxisEnd];
|
|
434
431
|
break;
|
|
435
432
|
}
|
|
@@ -445,18 +442,18 @@ function _getRenderableData(GraphicType, GraphicData, imageId, TrackingIdentifie
|
|
|
445
442
|
const worldPos = core_dist_esm.utilities.imageToWorldCoords(imageId, [GraphicData[i], GraphicData[i + 1]]);
|
|
446
443
|
pointsWorld.push(worldPos);
|
|
447
444
|
}
|
|
448
|
-
const majorAxisStart = esm/* vec3.fromValues */.
|
|
449
|
-
const majorAxisEnd = esm/* vec3.fromValues */.
|
|
450
|
-
const minorAxisStart = esm/* vec3.fromValues */.
|
|
451
|
-
const minorAxisEnd = esm/* vec3.fromValues */.
|
|
452
|
-
const majorAxisVec = esm/* vec3.create */.
|
|
453
|
-
esm/* vec3.sub */.
|
|
445
|
+
const majorAxisStart = esm/* vec3.fromValues */.eR.fromValues(...pointsWorld[0]);
|
|
446
|
+
const majorAxisEnd = esm/* vec3.fromValues */.eR.fromValues(...pointsWorld[1]);
|
|
447
|
+
const minorAxisStart = esm/* vec3.fromValues */.eR.fromValues(...pointsWorld[2]);
|
|
448
|
+
const minorAxisEnd = esm/* vec3.fromValues */.eR.fromValues(...pointsWorld[3]);
|
|
449
|
+
const majorAxisVec = esm/* vec3.create */.eR.create();
|
|
450
|
+
esm/* vec3.sub */.eR.sub(majorAxisVec, majorAxisEnd, majorAxisStart);
|
|
454
451
|
|
|
455
452
|
// normalize majorAxisVec to avoid scaling issues
|
|
456
|
-
esm/* vec3.normalize */.
|
|
457
|
-
const minorAxisVec = esm/* vec3.create */.
|
|
458
|
-
esm/* vec3.sub */.
|
|
459
|
-
esm/* vec3.normalize */.
|
|
453
|
+
esm/* vec3.normalize */.eR.normalize(majorAxisVec, majorAxisVec);
|
|
454
|
+
const minorAxisVec = esm/* vec3.create */.eR.create();
|
|
455
|
+
esm/* vec3.sub */.eR.sub(minorAxisVec, minorAxisEnd, minorAxisStart);
|
|
456
|
+
esm/* vec3.normalize */.eR.normalize(minorAxisVec, minorAxisVec);
|
|
460
457
|
const imagePlaneModule = core_dist_esm.metaData.get('imagePlaneModule', imageId);
|
|
461
458
|
if (!imagePlaneModule) {
|
|
462
459
|
throw new Error('imageId does not have imagePlaneModule metadata');
|
|
@@ -466,9 +463,9 @@ function _getRenderableData(GraphicType, GraphicData, imageId, TrackingIdentifie
|
|
|
466
463
|
} = imagePlaneModule;
|
|
467
464
|
|
|
468
465
|
// find which axis is parallel to the columnCosines
|
|
469
|
-
const columnCosinesVec = esm/* vec3.fromValues */.
|
|
470
|
-
const projectedMajorAxisOnColVec = Math.abs(esm/* vec3.dot */.
|
|
471
|
-
const projectedMinorAxisOnColVec = Math.abs(esm/* vec3.dot */.
|
|
466
|
+
const columnCosinesVec = esm/* vec3.fromValues */.eR.fromValues(...columnCosines);
|
|
467
|
+
const projectedMajorAxisOnColVec = Math.abs(esm/* vec3.dot */.eR.dot(columnCosinesVec, majorAxisVec));
|
|
468
|
+
const projectedMinorAxisOnColVec = Math.abs(esm/* vec3.dot */.eR.dot(columnCosinesVec, minorAxisVec));
|
|
472
469
|
const absoluteOfMajorDotProduct = Math.abs(projectedMajorAxisOnColVec);
|
|
473
470
|
const absoluteOfMinorDotProduct = Math.abs(projectedMinorAxisOnColVec);
|
|
474
471
|
renderableData = [];
|
|
@@ -487,10 +484,10 @@ function _getRenderableData(GraphicType, GraphicData, imageId, TrackingIdentifie
|
|
|
487
484
|
return renderableData;
|
|
488
485
|
}
|
|
489
486
|
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/adapters/dist/adapters.es.js
|
|
490
|
-
var adapters_es = __webpack_require__(
|
|
487
|
+
var adapters_es = __webpack_require__(83342);
|
|
491
488
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/isRehydratable.js
|
|
492
489
|
|
|
493
|
-
const cornerstoneAdapters = adapters_es
|
|
490
|
+
const cornerstoneAdapters = adapters_es/* adaptersSR */.QX.Cornerstone3D.MeasurementReport.CORNERSTONE_TOOL_CLASSES_BY_UTILITY_TYPE;
|
|
494
491
|
const isRehydratable_supportedLegacyCornerstoneTags = ['cornerstoneTools@^4.0.0'];
|
|
495
492
|
const CORNERSTONE_3D_TAG = cornerstoneAdapters.CORNERSTONE_3D_TAG;
|
|
496
493
|
|
|
@@ -546,7 +543,7 @@ function isRehydratable(displaySet, mappings) {
|
|
|
546
543
|
|
|
547
544
|
const {
|
|
548
545
|
CodeScheme: Cornerstone3DCodeScheme
|
|
549
|
-
} = adapters_es
|
|
546
|
+
} = adapters_es/* adaptersSR */.QX.Cornerstone3D;
|
|
550
547
|
const {
|
|
551
548
|
ImageSet,
|
|
552
549
|
MetadataProvider: metadataProvider
|
|
@@ -565,7 +562,6 @@ const sopClassUids = ['1.2.840.10008.5.1.4.1.1.88.11',
|
|
|
565
562
|
//COMPREHENSIVE_SR:
|
|
566
563
|
'1.2.840.10008.5.1.4.1.1.88.34' //COMPREHENSIVE_3D_SR:
|
|
567
564
|
];
|
|
568
|
-
|
|
569
565
|
const CORNERSTONE_3D_TOOLS_SOURCE_NAME = 'Cornerstone3DTools';
|
|
570
566
|
const CORNERSTONE_3D_TOOLS_SOURCE_VERSION = '0.1';
|
|
571
567
|
const validateSameStudyUID = (uid, instances) => {
|
|
@@ -589,7 +585,6 @@ const CodeNameCodeSequenceValues = {
|
|
|
589
585
|
// SRT
|
|
590
586
|
CornerstoneFreeText: Cornerstone3DCodeScheme.codeValues.CORNERSTONEFREETEXT //
|
|
591
587
|
};
|
|
592
|
-
|
|
593
588
|
const CodingSchemeDesignators = {
|
|
594
589
|
SRT: 'SRT',
|
|
595
590
|
CornerstoneCodeSchemes: [Cornerstone3DCodeScheme.CodingSchemeDesignator, 'CST4']
|
|
@@ -699,7 +694,7 @@ function _load(displaySet, servicesManager, extensionManager) {
|
|
|
699
694
|
|
|
700
695
|
// Check currently added displaySets and add measurements if the sources exist.
|
|
701
696
|
displaySetService.activeDisplaySets.forEach(activeDisplaySet => {
|
|
702
|
-
_checkIfCanAddMeasurementsToDisplaySet(displaySet, activeDisplaySet, dataSource);
|
|
697
|
+
_checkIfCanAddMeasurementsToDisplaySet(displaySet, activeDisplaySet, dataSource, servicesManager);
|
|
703
698
|
});
|
|
704
699
|
|
|
705
700
|
// Subscribe to new displaySets as the source may come in after.
|
|
@@ -710,11 +705,14 @@ function _load(displaySet, servicesManager, extensionManager) {
|
|
|
710
705
|
// If there are still some measurements that have not yet been loaded into cornerstone,
|
|
711
706
|
// See if we can load them onto any of the new displaySets.
|
|
712
707
|
displaySetsAdded.forEach(newDisplaySet => {
|
|
713
|
-
_checkIfCanAddMeasurementsToDisplaySet(displaySet, newDisplaySet, dataSource);
|
|
708
|
+
_checkIfCanAddMeasurementsToDisplaySet(displaySet, newDisplaySet, dataSource, servicesManager);
|
|
714
709
|
});
|
|
715
710
|
});
|
|
716
711
|
}
|
|
717
|
-
function _checkIfCanAddMeasurementsToDisplaySet(srDisplaySet, newDisplaySet, dataSource) {
|
|
712
|
+
function _checkIfCanAddMeasurementsToDisplaySet(srDisplaySet, newDisplaySet, dataSource, servicesManager) {
|
|
713
|
+
const {
|
|
714
|
+
customizationService
|
|
715
|
+
} = servicesManager.services;
|
|
718
716
|
let unloadedMeasurements = srDisplaySet.measurements.filter(measurement => measurement.loaded === false);
|
|
719
717
|
if (unloadedMeasurements.length === 0) {
|
|
720
718
|
// All already loaded!
|
|
@@ -724,9 +722,11 @@ function _checkIfCanAddMeasurementsToDisplaySet(srDisplaySet, newDisplaySet, dat
|
|
|
724
722
|
// This also filters out _this_ displaySet, as it is not an ImageSet.
|
|
725
723
|
return;
|
|
726
724
|
}
|
|
725
|
+
if (newDisplaySet.unsupported) {
|
|
726
|
+
return;
|
|
727
|
+
}
|
|
727
728
|
const {
|
|
728
|
-
sopClassUids
|
|
729
|
-
images
|
|
729
|
+
sopClassUids
|
|
730
730
|
} = newDisplaySet;
|
|
731
731
|
|
|
732
732
|
// Check if any have the newDisplaySet is the correct SOPClass.
|
|
@@ -759,7 +759,15 @@ function _checkIfCanAddMeasurementsToDisplaySet(srDisplaySet, newDisplaySet, dat
|
|
|
759
759
|
} = metadataProvider.getUIDsFromImageID(imageId);
|
|
760
760
|
if (SOPInstanceUIDs.includes(SOPInstanceUID)) {
|
|
761
761
|
for (let j = unloadedMeasurements.length - 1; j >= 0; j--) {
|
|
762
|
-
|
|
762
|
+
let measurement = unloadedMeasurements[j];
|
|
763
|
+
const onBeforeSRAddMeasurement = customizationService.getModeCustomization('onBeforeSRAddMeasurement')?.value;
|
|
764
|
+
if (typeof onBeforeSRAddMeasurement === 'function') {
|
|
765
|
+
measurement = onBeforeSRAddMeasurement({
|
|
766
|
+
measurement,
|
|
767
|
+
StudyInstanceUID: srDisplaySet.StudyInstanceUID,
|
|
768
|
+
SeriesInstanceUID: srDisplaySet.SeriesInstanceUID
|
|
769
|
+
});
|
|
770
|
+
}
|
|
763
771
|
if (_measurementReferencesSOPInstanceUID(measurement, SOPInstanceUID, frameNumber)) {
|
|
764
772
|
addMeasurement(measurement, imageId, newDisplaySet.displaySetInstanceUID);
|
|
765
773
|
unloadedMeasurements.splice(j, 1);
|
|
@@ -789,11 +797,10 @@ function _measurementReferencesSOPInstanceUID(measurement, SOPInstanceUID, frame
|
|
|
789
797
|
}
|
|
790
798
|
}
|
|
791
799
|
}
|
|
792
|
-
function getSopClassHandlerModule(
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
} = _ref;
|
|
800
|
+
function getSopClassHandlerModule({
|
|
801
|
+
servicesManager,
|
|
802
|
+
extensionManager
|
|
803
|
+
}) {
|
|
797
804
|
const getDisplaySetsFromSeries = instances => {
|
|
798
805
|
return _getDisplaySetsFromSeries(instances, servicesManager, extensionManager);
|
|
799
806
|
};
|
|
@@ -978,7 +985,6 @@ function _getLabelFromMeasuredValueSequence(ConceptNameCodeSequence, MeasuredVal
|
|
|
978
985
|
value: `${formatedNumericValue} ${CodeValue}`
|
|
979
986
|
}; // E.g. Long Axis: 31.0 mm
|
|
980
987
|
}
|
|
981
|
-
|
|
982
988
|
function _getReferencedImagesList(ImagingMeasurementReportContentSequence) {
|
|
983
989
|
const ImageLibrary = ImagingMeasurementReportContentSequence.find(item => item.ConceptNameCodeSequence.CodeValue === CodeNameCodeSequenceValues.ImageLibrary);
|
|
984
990
|
const ImageLibraryGroup = _getSequenceAsArray(ImageLibrary.ContentSequence).find(item => item.ConceptNameCodeSequence.CodeValue === CodeNameCodeSequenceValues.ImageLibraryGroup);
|
|
@@ -1078,10 +1084,9 @@ function getHangingProtocolModule() {
|
|
|
1078
1084
|
|
|
1079
1085
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/onModeEnter.js
|
|
1080
1086
|
|
|
1081
|
-
function onModeEnter(
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
} = _ref;
|
|
1087
|
+
function onModeEnter({
|
|
1088
|
+
servicesManager
|
|
1089
|
+
}) {
|
|
1085
1090
|
const {
|
|
1086
1091
|
displaySetService
|
|
1087
1092
|
} = servicesManager.services;
|
|
@@ -1093,13 +1098,13 @@ function onModeEnter(_ref) {
|
|
|
1093
1098
|
});
|
|
1094
1099
|
}
|
|
1095
1100
|
// EXTERNAL MODULE: ../../../node_modules/dcmjs/build/dcmjs.es.js
|
|
1096
|
-
var dcmjs_es = __webpack_require__(
|
|
1101
|
+
var dcmjs_es = __webpack_require__(31426);
|
|
1097
1102
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/getFilteredCornerstoneToolState.ts
|
|
1098
1103
|
|
|
1099
1104
|
|
|
1100
1105
|
const {
|
|
1101
1106
|
log
|
|
1102
|
-
} = src
|
|
1107
|
+
} = src/* default */.Ay;
|
|
1103
1108
|
function getFilteredCornerstoneToolState(measurementData, additionalFindingTypes) {
|
|
1104
1109
|
const filteredToolState = {};
|
|
1105
1110
|
function addToFilteredToolState(annotation, toolType) {
|
|
@@ -1187,10 +1192,10 @@ function getFilteredCornerstoneToolState(measurementData, additionalFindingTypes
|
|
|
1187
1192
|
|
|
1188
1193
|
const {
|
|
1189
1194
|
MeasurementReport
|
|
1190
|
-
} = adapters_es
|
|
1195
|
+
} = adapters_es/* adaptersSR */.QX.Cornerstone3D;
|
|
1191
1196
|
const {
|
|
1192
1197
|
log: commandsModule_log
|
|
1193
|
-
} = src
|
|
1198
|
+
} = src/* default */.Ay;
|
|
1194
1199
|
|
|
1195
1200
|
/**
|
|
1196
1201
|
*
|
|
@@ -1200,8 +1205,7 @@ const {
|
|
|
1200
1205
|
* @param options Naturalized DICOM JSON headers to merge into the displaySet.
|
|
1201
1206
|
*
|
|
1202
1207
|
*/
|
|
1203
|
-
const _generateReport =
|
|
1204
|
-
let options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
1208
|
+
const _generateReport = (measurementData, additionalFindingTypes, options = {}) => {
|
|
1205
1209
|
const filteredToolState = utils_getFilteredCornerstoneToolState(measurementData, additionalFindingTypes);
|
|
1206
1210
|
const report = MeasurementReport.generateReport(filteredToolState, core_dist_esm.metaData, core_dist_esm.utilities.worldToImageCoords, options);
|
|
1207
1211
|
const {
|
|
@@ -1215,8 +1219,13 @@ const _generateReport = function (measurementData, additionalFindingTypes) {
|
|
|
1215
1219
|
}
|
|
1216
1220
|
return dataset;
|
|
1217
1221
|
};
|
|
1218
|
-
const commandsModule =
|
|
1219
|
-
|
|
1222
|
+
const commandsModule = props => {
|
|
1223
|
+
const {
|
|
1224
|
+
servicesManager
|
|
1225
|
+
} = props;
|
|
1226
|
+
const {
|
|
1227
|
+
customizationService
|
|
1228
|
+
} = servicesManager.services;
|
|
1220
1229
|
const actions = {
|
|
1221
1230
|
/**
|
|
1222
1231
|
*
|
|
@@ -1226,14 +1235,13 @@ const commandsModule = _ref => {
|
|
|
1226
1235
|
* as opposed to Finding Sites.
|
|
1227
1236
|
* that you wish to serialize.
|
|
1228
1237
|
*/
|
|
1229
|
-
downloadReport:
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
} = _ref2;
|
|
1238
|
+
downloadReport: ({
|
|
1239
|
+
measurementData,
|
|
1240
|
+
additionalFindingTypes,
|
|
1241
|
+
options = {}
|
|
1242
|
+
}) => {
|
|
1235
1243
|
const srDataset = actions.generateReport(measurementData, additionalFindingTypes, options);
|
|
1236
|
-
const reportBlob = dcmjs_es
|
|
1244
|
+
const reportBlob = dcmjs_es/* default.data */.Ay.data.datasetToBlob(srDataset);
|
|
1237
1245
|
|
|
1238
1246
|
//Create a URL for the binary.
|
|
1239
1247
|
var objectUrl = URL.createObjectURL(reportBlob);
|
|
@@ -1248,13 +1256,12 @@ const commandsModule = _ref => {
|
|
|
1248
1256
|
* @param options Naturalized DICOM JSON headers to merge into the displaySet.
|
|
1249
1257
|
* @return The naturalized report
|
|
1250
1258
|
*/
|
|
1251
|
-
storeMeasurements: async
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
} = _ref3;
|
|
1259
|
+
storeMeasurements: async ({
|
|
1260
|
+
measurementData,
|
|
1261
|
+
dataSource,
|
|
1262
|
+
additionalFindingTypes,
|
|
1263
|
+
options = {}
|
|
1264
|
+
}) => {
|
|
1258
1265
|
// Use the @cornerstonejs adapter for converting to/from DICOM
|
|
1259
1266
|
// But it is good enough for now whilst we only have cornerstone as a datasource.
|
|
1260
1267
|
commandsModule_log.info('[DICOMSR] storeMeasurements');
|
|
@@ -1275,7 +1282,15 @@ const commandsModule = _ref => {
|
|
|
1275
1282
|
console.log('naturalizedReport missing imaging content', naturalizedReport);
|
|
1276
1283
|
throw new Error('Invalid report, no content');
|
|
1277
1284
|
}
|
|
1278
|
-
|
|
1285
|
+
const onBeforeDicomStore = customizationService.getModeCustomization('onBeforeDicomStore')?.value;
|
|
1286
|
+
let dicomDict;
|
|
1287
|
+
if (typeof onBeforeDicomStore === 'function') {
|
|
1288
|
+
dicomDict = onBeforeDicomStore({
|
|
1289
|
+
measurementData,
|
|
1290
|
+
naturalizedReport
|
|
1291
|
+
});
|
|
1292
|
+
}
|
|
1293
|
+
await dataSource.store.dicom(naturalizedReport, null, dicomDict);
|
|
1279
1294
|
if (StudyInstanceUID) {
|
|
1280
1295
|
dataSource.deleteStudyMetadataPromise(StudyInstanceUID);
|
|
1281
1296
|
}
|
|
@@ -1327,10 +1342,9 @@ function addToolInstance(name, toolClass, configuration) {
|
|
|
1327
1342
|
/**
|
|
1328
1343
|
* @param {object} configuration
|
|
1329
1344
|
*/
|
|
1330
|
-
function init(
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
} = _ref;
|
|
1345
|
+
function init({
|
|
1346
|
+
configuration = {}
|
|
1347
|
+
}) {
|
|
1334
1348
|
(0,dist_esm.addTool)(DICOMSRDisplayTool);
|
|
1335
1349
|
addToolInstance(tools_toolNames.SRLength, dist_esm.LengthTool, {});
|
|
1336
1350
|
addToolInstance(tools_toolNames.SRBidirectional, dist_esm.BidirectionalTool);
|
|
@@ -1361,7 +1375,7 @@ function init(_ref) {
|
|
|
1361
1375
|
});
|
|
1362
1376
|
}
|
|
1363
1377
|
// EXTERNAL MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/hydrateStructuredReport.js + 1 modules
|
|
1364
|
-
var hydrateStructuredReport = __webpack_require__(
|
|
1378
|
+
var hydrateStructuredReport = __webpack_require__(77089);
|
|
1365
1379
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/createReferencedImageDisplaySet.ts
|
|
1366
1380
|
|
|
1367
1381
|
const createReferencedImageDisplaySet_ImageSet = src.classes.ImageSet;
|
|
@@ -1460,7 +1474,7 @@ function _extends() { _extends = Object.assign ? Object.assign.bind() : function
|
|
|
1460
1474
|
|
|
1461
1475
|
|
|
1462
1476
|
const Component = /*#__PURE__*/react.lazy(() => {
|
|
1463
|
-
return __webpack_require__.e(/* import() */
|
|
1477
|
+
return __webpack_require__.e(/* import() */ 530).then(__webpack_require__.bind(__webpack_require__, 58530));
|
|
1464
1478
|
});
|
|
1465
1479
|
const OHIFCornerstoneSRViewport = props => {
|
|
1466
1480
|
return /*#__PURE__*/react.createElement(react.Suspense, {
|
|
@@ -1484,11 +1498,10 @@ const dicomSRExtension = {
|
|
|
1484
1498
|
* @param {object} [configuration={}]
|
|
1485
1499
|
* @param {object|array} [configuration.csToolsConfig] - Passed directly to `initCornerstoneTools`
|
|
1486
1500
|
*/
|
|
1487
|
-
getViewportModule(
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
} = _ref;
|
|
1501
|
+
getViewportModule({
|
|
1502
|
+
servicesManager,
|
|
1503
|
+
extensionManager
|
|
1504
|
+
}) {
|
|
1492
1505
|
const ExtendedOHIFCornerstoneSRViewport = props => {
|
|
1493
1506
|
return /*#__PURE__*/react.createElement(OHIFCornerstoneSRViewport, _extends({
|
|
1494
1507
|
servicesManager: servicesManager,
|
|
@@ -1503,10 +1516,9 @@ const dicomSRExtension = {
|
|
|
1503
1516
|
getCommandsModule: src_commandsModule,
|
|
1504
1517
|
getSopClassHandlerModule: src_getSopClassHandlerModule,
|
|
1505
1518
|
// Include dynamically computed values such as toolNames not known till instantiation
|
|
1506
|
-
getUtilityModule(
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
} = _ref2;
|
|
1519
|
+
getUtilityModule({
|
|
1520
|
+
servicesManager
|
|
1521
|
+
}) {
|
|
1510
1522
|
return [{
|
|
1511
1523
|
name: 'tools',
|
|
1512
1524
|
exports: {
|
|
@@ -1522,16 +1534,15 @@ const dicomSRExtension = {
|
|
|
1522
1534
|
|
|
1523
1535
|
/***/ }),
|
|
1524
1536
|
|
|
1525
|
-
/***/
|
|
1537
|
+
/***/ 74334:
|
|
1526
1538
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
1527
1539
|
|
|
1528
|
-
"use strict";
|
|
1529
1540
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
1530
|
-
/* harmony export */
|
|
1531
|
-
/* harmony export */
|
|
1541
|
+
/* harmony export */ eF: () => (/* binding */ getTrackingUniqueIdentifiersForElement),
|
|
1542
|
+
/* harmony export */ m1: () => (/* binding */ setTrackingUniqueIdentifiersForElement)
|
|
1532
1543
|
/* harmony export */ });
|
|
1533
1544
|
/* unused harmony export setActiveTrackingUniqueIdentifierForElement */
|
|
1534
|
-
/* harmony import */ var _cornerstonejs_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
|
|
1545
|
+
/* harmony import */ var _cornerstonejs_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(39526);
|
|
1535
1546
|
|
|
1536
1547
|
const state = {
|
|
1537
1548
|
TrackingUniqueIdentifier: null,
|
|
@@ -1546,8 +1557,7 @@ const state = {
|
|
|
1546
1557
|
* of the SR tools in state here, so that we can filter them later.
|
|
1547
1558
|
*/
|
|
1548
1559
|
|
|
1549
|
-
function setTrackingUniqueIdentifiersForElement(element, trackingUniqueIdentifiers) {
|
|
1550
|
-
let activeIndex = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
|
1560
|
+
function setTrackingUniqueIdentifiersForElement(element, trackingUniqueIdentifiers, activeIndex = 0) {
|
|
1551
1561
|
const enabledElement = (0,_cornerstonejs_core__WEBPACK_IMPORTED_MODULE_0__.getEnabledElement)(element);
|
|
1552
1562
|
const {
|
|
1553
1563
|
viewport
|
|
@@ -1584,20 +1594,19 @@ function getTrackingUniqueIdentifiersForElement(element) {
|
|
|
1584
1594
|
|
|
1585
1595
|
/***/ }),
|
|
1586
1596
|
|
|
1587
|
-
/***/
|
|
1597
|
+
/***/ 77089:
|
|
1588
1598
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
1589
1599
|
|
|
1590
|
-
"use strict";
|
|
1591
1600
|
|
|
1592
1601
|
// EXPORTS
|
|
1593
1602
|
__webpack_require__.d(__webpack_exports__, {
|
|
1594
|
-
|
|
1603
|
+
A: () => (/* binding */ hydrateStructuredReport)
|
|
1595
1604
|
});
|
|
1596
1605
|
|
|
1597
|
-
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/core/dist/esm/index.js +
|
|
1598
|
-
var esm = __webpack_require__(
|
|
1599
|
-
// EXTERNAL MODULE: ../../core/src/index.ts +
|
|
1600
|
-
var src = __webpack_require__(
|
|
1606
|
+
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/core/dist/esm/index.js + 382 modules
|
|
1607
|
+
var esm = __webpack_require__(39526);
|
|
1608
|
+
// EXTERNAL MODULE: ../../core/src/index.ts + 66 modules
|
|
1609
|
+
var src = __webpack_require__(14283);
|
|
1601
1610
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/getLabelFromDCMJSImportedToolData.js
|
|
1602
1611
|
/**
|
|
1603
1612
|
* Extracts the label from the toolData imported from dcmjs. We need to do this
|
|
@@ -1621,9 +1630,9 @@ function getLabelFromDCMJSImportedToolData(toolData) {
|
|
|
1621
1630
|
}
|
|
1622
1631
|
}
|
|
1623
1632
|
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/adapters/dist/adapters.es.js
|
|
1624
|
-
var adapters_es = __webpack_require__(
|
|
1625
|
-
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/tools/dist/esm/index.js +
|
|
1626
|
-
var dist_esm = __webpack_require__(
|
|
1633
|
+
var adapters_es = __webpack_require__(83342);
|
|
1634
|
+
// EXTERNAL MODULE: ../../../node_modules/@cornerstonejs/tools/dist/esm/index.js + 14 modules
|
|
1635
|
+
var dist_esm = __webpack_require__(72980);
|
|
1627
1636
|
;// CONCATENATED MODULE: ../../../extensions/cornerstone-dicom-sr/src/utils/hydrateStructuredReport.js
|
|
1628
1637
|
|
|
1629
1638
|
|
|
@@ -1635,11 +1644,11 @@ const {
|
|
|
1635
1644
|
} = dist_esm.annotation;
|
|
1636
1645
|
const {
|
|
1637
1646
|
guid
|
|
1638
|
-
} = src
|
|
1647
|
+
} = src/* default.utils */.Ay.utils;
|
|
1639
1648
|
const {
|
|
1640
1649
|
MeasurementReport,
|
|
1641
1650
|
CORNERSTONE_3D_TAG
|
|
1642
|
-
} = adapters_es
|
|
1651
|
+
} = adapters_es/* adaptersSR */.QX.Cornerstone3D;
|
|
1643
1652
|
const CORNERSTONE_3D_TOOLS_SOURCE_NAME = 'Cornerstone3DTools';
|
|
1644
1653
|
const CORNERSTONE_3D_TOOLS_SOURCE_VERSION = '0.1';
|
|
1645
1654
|
const supportedLegacyCornerstoneTags = ['cornerstoneTools@^4.0.0'];
|
|
@@ -1676,12 +1685,11 @@ const convertSites = (codingValues, sites) => {
|
|
|
1676
1685
|
* Hydrates a structured report, for default viewports.
|
|
1677
1686
|
*
|
|
1678
1687
|
*/
|
|
1679
|
-
function hydrateStructuredReport(
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
} = _ref;
|
|
1688
|
+
function hydrateStructuredReport({
|
|
1689
|
+
servicesManager,
|
|
1690
|
+
extensionManager,
|
|
1691
|
+
appConfig
|
|
1692
|
+
}, displaySetInstanceUID) {
|
|
1685
1693
|
const annotationManager = dist_esm.annotation.state.getAnnotationManager();
|
|
1686
1694
|
const disableEditing = appConfig?.disableEditing;
|
|
1687
1695
|
const dataSource = extensionManager.getActiveDataSource()[0];
|
|
@@ -1718,12 +1726,19 @@ function hydrateStructuredReport(_ref, displaySetInstanceUID) {
|
|
|
1718
1726
|
const datasetToUse = _mapLegacyDataSet(instance);
|
|
1719
1727
|
|
|
1720
1728
|
// Use dcmjs to generate toolState.
|
|
1721
|
-
|
|
1729
|
+
let storedMeasurementByAnnotationType = MeasurementReport.generateToolState(datasetToUse,
|
|
1722
1730
|
// NOTE: we need to pass in the imageIds to dcmjs since the we use them
|
|
1723
1731
|
// for the imageToWorld transformation. The following assumes that the order
|
|
1724
1732
|
// that measurements were added to the display set are the same order as
|
|
1725
1733
|
// the measurementGroups in the instance.
|
|
1726
1734
|
sopInstanceUIDToImageId, esm.utilities.imageToWorldCoords, esm.metaData);
|
|
1735
|
+
const onBeforeSRHydration = customizationService.getModeCustomization('onBeforeSRHydration')?.value;
|
|
1736
|
+
if (typeof onBeforeSRHydration === 'function') {
|
|
1737
|
+
storedMeasurementByAnnotationType = onBeforeSRHydration({
|
|
1738
|
+
storedMeasurementByAnnotationType,
|
|
1739
|
+
displaySet
|
|
1740
|
+
});
|
|
1741
|
+
}
|
|
1727
1742
|
|
|
1728
1743
|
// Filter what is found by DICOM SR to measurements we support.
|
|
1729
1744
|
const mappingDefinitions = mappings.map(m => m.annotationType);
|
|
@@ -1860,13 +1875,6 @@ const codeMeaningEquals = codeMeaningName => {
|
|
|
1860
1875
|
};
|
|
1861
1876
|
};
|
|
1862
1877
|
|
|
1863
|
-
/***/ }),
|
|
1864
|
-
|
|
1865
|
-
/***/ 78753:
|
|
1866
|
-
/***/ (() => {
|
|
1867
|
-
|
|
1868
|
-
/* (ignored) */
|
|
1869
|
-
|
|
1870
1878
|
/***/ })
|
|
1871
1879
|
|
|
1872
1880
|
}]);
|