@ohif/app 3.8.0-beta.73 → 3.8.0-beta.75

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.
Files changed (46) hide show
  1. package/dist/{121.bundle.21827fec690c01ee9ab3.js → 121.bundle.bd8acf52b6a7047ae832.js} +2 -2
  2. package/dist/141.bundle.556b4c1e4cab770417ac.js +8620 -0
  3. package/dist/{191.bundle.c0ea2d031ffddeca32c9.js → 183.bundle.25293de927ef032a6695.js} +195 -122
  4. package/dist/{188.bundle.acfe3c0e6eb9cc90aef1.js → 188.bundle.e992f05e4e8166db89c4.js} +2 -2
  5. package/dist/{90.bundle.70f4752bb4ac79aef269.js → 206.bundle.88019f84ccd7fb9276e7.js} +580 -140
  6. package/dist/{987.bundle.e19408decfd59aadd118.js → 217.bundle.9631d914f170f8d7ef63.js} +31558 -39396
  7. package/dist/{295.bundle.3a0d5062d65296c4bf5d.js → 295.bundle.688b6bbff493cd904ae7.js} +2 -2
  8. package/dist/{155.bundle.64e00e96835d61e99c0e.js → 325.bundle.52287c47a07bb16869cb.js} +43 -58
  9. package/dist/{425.bundle.f796ed1020fbed0f1e71.js → 335.bundle.8ed90c9c715dafb05c77.js} +132 -518
  10. package/dist/{342.bundle.521c0217f82380c0c2ad.js → 342.bundle.c6165579c4ac3ef0d6a8.js} +2 -2
  11. package/dist/{41.bundle.8b3f6e6f4bd71b85ef14.js → 41.bundle.6a01588b0e9bf25372ea.js} +28 -29
  12. package/dist/{433.bundle.6f2308ab10593784778c.js → 433.bundle.1474591f213852cffcba.js} +188 -172
  13. package/dist/{290.bundle.952de53057f98e2c5ef0.js → 445.bundle.38c6d2af64e41cd7c614.js} +1 -1049
  14. package/dist/{448.bundle.19df2fef38bb0f6a272a.js → 448.bundle.eb2e38dfa7fd0d731109.js} +16 -22
  15. package/dist/487.bundle.c7a54a90b005e5b977df.js +1875 -0
  16. package/dist/{530.bundle.f4b7966fb33eafb8cd5d.js → 530.bundle.7c94543955552475c56a.js} +9 -9
  17. package/dist/{540.bundle.32224b29bfa11d1f1cec.js → 540.bundle.45a7a300cc09906b4acc.js} +15 -15
  18. package/dist/{544.bundle.1110b24e96863d719a95.js → 544.bundle.1c1f57118560046649c1.js} +9 -17
  19. package/dist/{574.bundle.2b3369042aad5d553463.js → 574.bundle.b4eb8773d7741868e84b.js} +166 -45
  20. package/dist/{594.bundle.61a9f0567260e9bb4480.js → 594.bundle.6a804bd412dbf955c5b9.js} +4 -4
  21. package/dist/{2.bundle.a849401e1fefc0898248.js → 633.bundle.65ed703c889005f8ffa8.js} +35 -43
  22. package/dist/{699.bundle.9f4eddf87548c0d0dca3.js → 699.bundle.d672e71097df9be1b2a7.js} +18 -35
  23. package/dist/702.bundle.963481fbf871984b646f.js +8426 -0
  24. package/dist/722.bundle.afab1fe6bfcd569130ac.js +1083 -0
  25. package/dist/{724.bundle.b57096deac9649aada4b.js → 724.bundle.73c3bd976d8a7f1d040c.js} +20 -11
  26. package/dist/{862.bundle.47305c27f0fb939c2f97.js → 862.bundle.f49a379497bb3b43a942.js} +3 -3
  27. package/dist/{889.bundle.3816444220909bd1fc78.js → 889.bundle.fa29b24385d14e4fa4fd.js} +8 -8
  28. package/dist/{595.bundle.e8ff2d0672cb195d4ab8.js → 896.bundle.2635ab03af0b472f6e39.js} +686 -57
  29. package/dist/{905.bundle.2dd7f62cb6e49851926b.js → 905.bundle.9f0b28f4bf91fffdc90c.js} +4 -4
  30. package/dist/{907.bundle.d22edc6203167e985ab3.js → 907.bundle.7c64be49c9a44fbd1e61.js} +2 -2
  31. package/dist/94.bundle.e9ca76b8e5c4000c9742.js +784 -0
  32. package/dist/{961.bundle.f207f1ac54a174e67d82.js → 961.bundle.d1888c50a49e80380c69.js} +2 -2
  33. package/dist/{app.bundle.5e5ee16c43a68961e8c4.js → app.bundle.a6eb6707172f9eb6c8c2.js} +98584 -89435
  34. package/dist/app.bundle.css +5 -4
  35. package/dist/cornerstoneDICOMImageLoader.min.js +1 -1
  36. package/dist/cornerstoneDICOMImageLoader.min.js.map +1 -1
  37. package/dist/histogram-worker.bundle.829e14ec12c2b41a4323.js +359 -0
  38. package/dist/index.html +1 -1
  39. package/dist/{polySeg.bundle.fe47718e6a8414f175b1.js → polySeg.bundle.c503e9460cef894737cd.js} +3 -6
  40. package/dist/sw.js +1 -1
  41. package/package.json +20 -19
  42. package/dist/425.css +0 -2
  43. /package/dist/{164.bundle.6b98e9caf53620fbd6ca.js → 164.bundle.2fd64799a0bae7596af8.js} +0 -0
  44. /package/dist/{155.css → 325.css} +0 -0
  45. /package/dist/{2.css → 633.css} +0 -0
  46. /package/dist/{595.css → 896.css} +0 -0
@@ -0,0 +1,784 @@
1
+ "use strict";
2
+ (globalThis["webpackChunk"] = globalThis["webpackChunk"] || []).push([[94],{
3
+
4
+ /***/ 14094:
5
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
6
+
7
+ // ESM COMPAT FLAG
8
+ __webpack_require__.r(__webpack_exports__);
9
+
10
+ // EXPORTS
11
+ __webpack_require__.d(__webpack_exports__, {
12
+ "default": () => (/* binding */ preclinical_4d_src)
13
+ });
14
+
15
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/package.json
16
+ const package_namespaceObject = /*#__PURE__*/JSON.parse('{"UU":"@ohif/mode-preclinical-4d"}');
17
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/id.js
18
+
19
+ const id = package_namespaceObject.UU;
20
+
21
+ // EXTERNAL MODULE: ../../core/src/index.ts + 70 modules
22
+ var src = __webpack_require__(55411);
23
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/getWorkflowSettings.ts
24
+ const dynamicVolume = {
25
+ sopClassHandler: '@ohif/extension-cornerstone-dynamic-volume.sopClassHandlerModule.dynamic-volume',
26
+ leftPanel: '@ohif/extension-cornerstone-dynamic-volume.panelModule.dynamic-volume',
27
+ toolBox: '@ohif/extension-cornerstone-dynamic-volume.panelModule.dynamic-toolbox',
28
+ export: '@ohif/extension-cornerstone-dynamic-volume.panelModule.dynamic-export'
29
+ };
30
+ const cornerstone = {
31
+ segmentation: '@ohif/extension-cornerstone-dicom-seg.panelModule.panelSegmentation',
32
+ activeViewportWindowLevel: '@ohif/extension-cornerstone.panelModule.activeViewportWindowLevel'
33
+ };
34
+ const defaultButtons = {
35
+ buttonSection: 'primary',
36
+ buttons: ['MeasurementTools', 'Zoom', 'WindowLevel', 'Crosshairs', 'Pan']
37
+ };
38
+ const defaultLeftPanel = [[dynamicVolume.leftPanel, cornerstone.activeViewportWindowLevel]];
39
+ const defaultLayout = {
40
+ panels: {
41
+ left: defaultLeftPanel,
42
+ right: []
43
+ }
44
+ };
45
+ function getWorkflowSettings({
46
+ servicesManager
47
+ }) {
48
+ return {
49
+ steps: [{
50
+ id: 'dataPreparation',
51
+ name: 'Data Preparation',
52
+ layout: {
53
+ panels: {
54
+ left: defaultLeftPanel
55
+ }
56
+ },
57
+ toolbarButtons: defaultButtons,
58
+ hangingProtocol: {
59
+ protocolId: 'default4D',
60
+ stageId: 'dataPreparation'
61
+ },
62
+ info: 'In the Data Preparation step, you can visualize the dynamic PT volume data in three orthogonal views: axial, sagittal, and coronal. Use the left panel controls to adjust the visualization settings, such as playback speed, or navigate between different frames. This step allows you to assess the quality of the PT data and prepare for further analysis or registration with other modalities.'
63
+ }, {
64
+ id: 'registration',
65
+ name: 'Registration',
66
+ layout: defaultLayout,
67
+ toolbarButtons: defaultButtons,
68
+ hangingProtocol: {
69
+ protocolId: 'default4D',
70
+ stageId: 'registration'
71
+ },
72
+ info: 'The Registration step provides a comprehensive view of the CT, PT, and fused CT-PT volume data in multiple orientations. The fusion viewports display the CT and PT volumes overlaid, allowing you to visually assess the alignment and registration between the two modalities. The individual CT and PT viewports are also available for side-by-side comparison. This step is crucial for ensuring proper registration before proceeding with further analysis or quantification.'
73
+ }, {
74
+ id: 'roiQuantification',
75
+ name: 'ROI Quantification',
76
+ layout: {
77
+ panels: {
78
+ left: defaultLeftPanel,
79
+ right: [[dynamicVolume.toolBox, cornerstone.segmentation, dynamicVolume.export]]
80
+ },
81
+ options: {
82
+ leftPanelClosed: false,
83
+ rightPanelClosed: false
84
+ }
85
+ },
86
+ toolbarButtons: [defaultButtons, {
87
+ buttonSection: 'dynamic-toolbox',
88
+ buttons: ['BrushTools', 'RectangleROIStartEndThreshold']
89
+ }],
90
+ hangingProtocol: {
91
+ protocolId: 'default4D',
92
+ stageId: 'roiQuantification'
93
+ },
94
+ info: 'The ROI quantification step allows you to define regions of interest (ROIs) with labelmap segmentations, on the fused CT-PT volume data using the labelmap tools. The left panel provides controls for adjusting the dynamic volume visualization, while the right panel offers tools for segmentation, editing, and exporting the ROI data. This step enables you to quantify the uptake or other measures within the defined ROIs for further analysis.'
95
+ }, {
96
+ id: 'kineticAnalysis',
97
+ name: 'Kinetic Analysis',
98
+ layout: defaultLayout,
99
+ toolbarButtons: defaultButtons,
100
+ hangingProtocol: {
101
+ protocolId: 'default4D',
102
+ stageId: 'kineticAnalysis'
103
+ },
104
+ onEnter: [{
105
+ commandName: 'updateSegmentationsChartDisplaySet',
106
+ options: {
107
+ servicesManager
108
+ }
109
+ }],
110
+ info: 'The Kinetic Analysis step provides a comprehensive view for visualizing and analyzing the dynamic data derived from the ROI segmentations. The fusion viewports display the combined CT-PT volume data, while a dedicated viewport shows a series chart representing the data over time. This step allows you to explore the temporal dynamics of the uptake or other kinetic measures within the defined regions of interest, enabling further quantitative analysis and modeling.'
111
+ }]
112
+ };
113
+ }
114
+
115
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/initWorkflowSteps.ts
116
+
117
+ function initWorkflowSteps({
118
+ servicesManager
119
+ }) {
120
+ const {
121
+ workflowStepsService
122
+ } = servicesManager.services;
123
+ const workflowSettings = getWorkflowSettings({
124
+ servicesManager
125
+ });
126
+ workflowStepsService.addWorkflowSteps(workflowSettings.steps);
127
+ workflowStepsService.setActiveWorkflowStep(workflowSettings.steps[0].id);
128
+ }
129
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/initToolGroups.tsx
130
+ const toolGroupIds = {
131
+ default: 'dynamic4D-default',
132
+ PT: 'dynamic4D-pt',
133
+ Fusion: 'dynamic4D-fusion',
134
+ CT: 'dynamic4D-ct'
135
+ };
136
+ function _initToolGroups(toolNames, Enums, toolGroupService, commandsManager) {
137
+ const tools = {
138
+ active: [{
139
+ toolName: toolNames.WindowLevel,
140
+ bindings: [{
141
+ mouseButton: Enums.MouseBindings.Primary
142
+ }]
143
+ }, {
144
+ toolName: toolNames.Pan,
145
+ bindings: [{
146
+ mouseButton: Enums.MouseBindings.Auxiliary
147
+ }]
148
+ }, {
149
+ toolName: toolNames.Zoom,
150
+ bindings: [{
151
+ mouseButton: Enums.MouseBindings.Secondary
152
+ }]
153
+ }, {
154
+ toolName: toolNames.StackScrollMouseWheel,
155
+ bindings: []
156
+ }],
157
+ passive: [{
158
+ toolName: toolNames.Length
159
+ }, {
160
+ toolName: toolNames.ArrowAnnotate
161
+ }, {
162
+ toolName: toolNames.Bidirectional
163
+ }, {
164
+ toolName: toolNames.Probe
165
+ }, {
166
+ toolName: toolNames.EllipticalROI
167
+ }, {
168
+ toolName: toolNames.RectangleROI
169
+ }, {
170
+ toolName: toolNames.RectangleROIThreshold
171
+ }, {
172
+ toolName: toolNames.RectangleScissors
173
+ }, {
174
+ toolName: toolNames.PaintFill
175
+ }, {
176
+ toolName: toolNames.StackScroll
177
+ }, {
178
+ toolName: toolNames.Magnify
179
+ }, {
180
+ toolName: 'CircularBrush',
181
+ parentTool: 'Brush',
182
+ configuration: {
183
+ activeStrategy: 'FILL_INSIDE_CIRCLE',
184
+ brushSize: 7
185
+ }
186
+ }, {
187
+ toolName: 'CircularEraser',
188
+ parentTool: 'Brush',
189
+ configuration: {
190
+ activeStrategy: 'ERASE_INSIDE_CIRCLE',
191
+ brushSize: 7
192
+ }
193
+ }, {
194
+ toolName: 'SphereBrush',
195
+ parentTool: 'Brush',
196
+ configuration: {
197
+ activeStrategy: 'FILL_INSIDE_SPHERE',
198
+ brushSize: 7
199
+ }
200
+ }, {
201
+ toolName: 'SphereEraser',
202
+ parentTool: 'Brush',
203
+ configuration: {
204
+ activeStrategy: 'ERASE_INSIDE_SPHERE',
205
+ brushSize: 7
206
+ }
207
+ }, {
208
+ toolName: 'ThresholdCircularBrush',
209
+ parentTool: 'Brush',
210
+ configuration: {
211
+ activeStrategy: 'THRESHOLD_INSIDE_CIRCLE',
212
+ brushSize: 7
213
+ }
214
+ }, {
215
+ toolName: 'ThresholdSphereBrush',
216
+ parentTool: 'Brush',
217
+ configuration: {
218
+ activeStrategy: 'THRESHOLD_INSIDE_SPHERE',
219
+ brushSize: 7
220
+ }
221
+ }, {
222
+ toolName: toolNames.CircleScissors
223
+ }, {
224
+ toolName: toolNames.RectangleScissors
225
+ }, {
226
+ toolName: toolNames.SphereScissors
227
+ }, {
228
+ toolName: toolNames.StackScroll
229
+ }, {
230
+ toolName: toolNames.Magnify
231
+ }, {
232
+ toolName: toolNames.SegmentationDisplay
233
+ }],
234
+ enabled: [{
235
+ toolName: toolNames.SegmentationDisplay
236
+ }],
237
+ disabled: [{
238
+ toolName: toolNames.Crosshairs,
239
+ configuration: {
240
+ viewportIndicators: false,
241
+ disableOnPassive: true,
242
+ autoPan: {
243
+ enabled: false,
244
+ panSize: 10
245
+ }
246
+ }
247
+ }]
248
+ };
249
+ toolGroupService.createToolGroupAndAddTools(toolGroupIds.PT, {
250
+ ...tools,
251
+ passive: [...tools.passive, {
252
+ toolName: 'RectangleROIStartEndThreshold'
253
+ }]
254
+ });
255
+ toolGroupService.createToolGroupAndAddTools(toolGroupIds.CT, {
256
+ ...tools,
257
+ passive: [...tools.passive, {
258
+ toolName: 'RectangleROIStartEndThreshold'
259
+ }]
260
+ });
261
+ toolGroupService.createToolGroupAndAddTools(toolGroupIds.Fusion, {
262
+ ...tools,
263
+ passive: [...tools.passive, {
264
+ toolName: 'RectangleROIStartEndThreshold'
265
+ }]
266
+ });
267
+ toolGroupService.createToolGroupAndAddTools(toolGroupIds.default, tools);
268
+ }
269
+ function initToolGroups({
270
+ toolNames,
271
+ Enums,
272
+ toolGroupService,
273
+ commandsManager
274
+ }) {
275
+ _initToolGroups(toolNames, Enums, toolGroupService, commandsManager);
276
+ }
277
+
278
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/toolbarButtons.tsx
279
+
280
+
281
+ const {
282
+ createButton
283
+ } = src.ToolbarService;
284
+ const setToolActiveToolbar = {
285
+ commandName: 'setToolActiveToolbar',
286
+ commandOptions: {
287
+ toolGroupIds: [toolGroupIds.PT, toolGroupIds.CT, toolGroupIds.Fusion, toolGroupIds.default]
288
+ }
289
+ };
290
+ const toolbarButtons = [{
291
+ id: 'MeasurementTools',
292
+ uiType: 'ohif.splitButton',
293
+ props: {
294
+ groupId: 'MeasurementTools',
295
+ evaluate: 'evaluate.group.promoteToPrimaryIfCornerstoneToolNotActiveInTheList',
296
+ primary: createButton({
297
+ id: 'Length',
298
+ icon: 'tool-length',
299
+ label: 'Length',
300
+ tooltip: 'Length Tool',
301
+ commands: setToolActiveToolbar,
302
+ evaluate: 'evaluate.cornerstoneTool'
303
+ }),
304
+ secondary: {
305
+ icon: 'chevron-down',
306
+ tooltip: 'More Measure Tools'
307
+ },
308
+ items: [{
309
+ id: 'Length',
310
+ icon: 'tool-length',
311
+ label: 'Length',
312
+ tooltip: 'Length Tool',
313
+ commands: setToolActiveToolbar,
314
+ evaluate: 'evaluate.cornerstoneTool'
315
+ }, {
316
+ id: 'Bidirectional',
317
+ icon: 'tool-bidirectional',
318
+ label: 'Bidirectional',
319
+ tooltip: 'Bidirectional Tool',
320
+ commands: setToolActiveToolbar,
321
+ evaluate: 'evaluate.cornerstoneTool'
322
+ }, {
323
+ id: 'ArrowAnnotate',
324
+ icon: 'tool-annotate',
325
+ label: 'Annotation',
326
+ tooltip: 'Arrow Annotate',
327
+ commands: setToolActiveToolbar,
328
+ evaluate: 'evaluate.cornerstoneTool'
329
+ }, {
330
+ id: 'EllipticalROI',
331
+ icon: 'tool-ellipse',
332
+ label: 'Ellipse',
333
+ tooltip: 'Ellipse ROI',
334
+ commands: setToolActiveToolbar,
335
+ evaluate: 'evaluate.cornerstoneTool'
336
+ }]
337
+ }
338
+ }, {
339
+ id: 'Zoom',
340
+ uiType: 'ohif.radioGroup',
341
+ props: {
342
+ icon: 'tool-zoom',
343
+ label: 'Zoom',
344
+ commands: setToolActiveToolbar,
345
+ evaluate: 'evaluate.cornerstoneTool'
346
+ }
347
+ }, {
348
+ id: 'WindowLevel',
349
+ uiType: 'ohif.radioGroup',
350
+ props: {
351
+ icon: 'tool-window-level',
352
+ label: 'Window Level',
353
+ commands: setToolActiveToolbar,
354
+ evaluate: 'evaluate.cornerstoneTool'
355
+ }
356
+ }, {
357
+ id: 'Pan',
358
+ uiType: 'ohif.radioGroup',
359
+ props: {
360
+ type: 'tool',
361
+ icon: 'tool-move',
362
+ label: 'Pan',
363
+ commands: setToolActiveToolbar,
364
+ evaluate: 'evaluate.cornerstoneTool'
365
+ }
366
+ }, {
367
+ id: 'TrackballRotate',
368
+ uiType: 'ohif.radioGroup',
369
+ props: {
370
+ type: 'tool',
371
+ icon: 'tool-3d-rotate',
372
+ label: '3D Rotate',
373
+ commands: setToolActiveToolbar,
374
+ evaluate: 'evaluate.cornerstoneTool'
375
+ }
376
+ }, {
377
+ id: 'Capture',
378
+ uiType: 'ohif.radioGroup',
379
+ props: {
380
+ icon: 'tool-capture',
381
+ label: 'Capture',
382
+ commands: 'showDownloadViewportModal',
383
+ evaluate: 'evaluate.action'
384
+ }
385
+ }, {
386
+ id: 'Layout',
387
+ uiType: 'ohif.layoutSelector',
388
+ props: {
389
+ rows: 3,
390
+ columns: 4,
391
+ evaluate: 'evaluate.action'
392
+ }
393
+ }, {
394
+ id: 'Crosshairs',
395
+ uiType: 'ohif.radioGroup',
396
+ props: {
397
+ type: 'tool',
398
+ icon: 'tool-crosshair',
399
+ label: 'Crosshairs',
400
+ commands: setToolActiveToolbar,
401
+ evaluate: 'evaluate.cornerstoneTool'
402
+ }
403
+ }, {
404
+ id: 'ProgressDropdown',
405
+ uiType: 'ohif.progressDropdown'
406
+ }, {
407
+ id: 'RectangleROIStartEndThreshold',
408
+ uiType: 'ohif.radioGroup',
409
+ props: {
410
+ icon: 'tool-create-threshold',
411
+ label: 'Rectangle ROI Threshold',
412
+ commands: setToolActiveToolbar,
413
+ evaluate: {
414
+ name: 'evaluate.cornerstone.segmentation',
415
+ toolNames: ['RectangleROIStartEndThreshold']
416
+ },
417
+ options: 'tmtv.RectangleROIThresholdOptions'
418
+ }
419
+ }];
420
+ /* harmony default export */ const src_toolbarButtons = (toolbarButtons);
421
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/segmentationButtons.ts
422
+ function _createSetToolActiveCommands(toolName) {
423
+ return [{
424
+ commandName: 'setToolActive',
425
+ commandOptions: {
426
+ toolName
427
+ }
428
+ }];
429
+ }
430
+ const segmentationButtons_toolbarButtons = [{
431
+ id: 'BrushTools',
432
+ uiType: 'ohif.buttonGroup',
433
+ props: {
434
+ groupId: 'BrushTools',
435
+ items: [{
436
+ id: 'Brush',
437
+ icon: 'icon-tool-brush',
438
+ label: 'Brush',
439
+ evaluate: {
440
+ name: 'evaluate.cornerstone.segmentation',
441
+ options: {
442
+ toolNames: ['CircularBrush', 'SphereBrush']
443
+ }
444
+ },
445
+ commands: _createSetToolActiveCommands('CircularBrush'),
446
+ options: [{
447
+ name: 'Radius (mm)',
448
+ id: 'brush-radius',
449
+ type: 'range',
450
+ min: 0.5,
451
+ max: 99.5,
452
+ step: 0.5,
453
+ value: 7,
454
+ commands: {
455
+ commandName: 'setBrushSize',
456
+ commandOptions: {
457
+ toolNames: ['CircularBrush', 'SphereBrush']
458
+ }
459
+ }
460
+ }, {
461
+ name: 'Shape',
462
+ type: 'radio',
463
+ id: 'brush-mode',
464
+ value: 'CircularBrush',
465
+ values: [{
466
+ value: 'CircularBrush',
467
+ label: 'Circle'
468
+ }, {
469
+ value: 'SphereBrush',
470
+ label: 'Sphere'
471
+ }],
472
+ commands: 'setToolActiveToolbar'
473
+ }]
474
+ }, {
475
+ id: 'Eraser',
476
+ icon: 'icon-tool-eraser',
477
+ label: 'Eraser',
478
+ evaluate: {
479
+ name: 'evaluate.cornerstone.segmentation',
480
+ options: {
481
+ toolNames: ['CircularEraser', 'SphereEraser']
482
+ }
483
+ },
484
+ commands: _createSetToolActiveCommands('CircularEraser'),
485
+ options: [{
486
+ name: 'Radius (mm)',
487
+ id: 'eraser-radius',
488
+ type: 'range',
489
+ min: 0.5,
490
+ max: 99.5,
491
+ step: 0.5,
492
+ value: 7,
493
+ commands: {
494
+ commandName: 'setBrushSize',
495
+ commandOptions: {
496
+ toolNames: ['CircularEraser', 'SphereEraser']
497
+ }
498
+ }
499
+ }, {
500
+ name: 'Shape',
501
+ type: 'radio',
502
+ id: 'eraser-mode',
503
+ value: 'CircularEraser',
504
+ values: [{
505
+ value: 'CircularEraser',
506
+ label: 'Circle'
507
+ }, {
508
+ value: 'SphereEraser',
509
+ label: 'Sphere'
510
+ }],
511
+ commands: 'setToolActiveToolbar'
512
+ }]
513
+ }, {
514
+ id: 'Threshold',
515
+ icon: 'icon-tool-threshold',
516
+ label: 'Eraser',
517
+ evaluate: {
518
+ name: 'evaluate.cornerstone.segmentation',
519
+ options: {
520
+ toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush']
521
+ }
522
+ },
523
+ commands: _createSetToolActiveCommands('ThresholdCircularBrush'),
524
+ options: [{
525
+ name: 'Radius (mm)',
526
+ id: 'threshold-radius',
527
+ type: 'range',
528
+ min: 0.5,
529
+ max: 99.5,
530
+ step: 0.5,
531
+ value: 7,
532
+ commands: {
533
+ commandName: 'setBrushSize',
534
+ commandOptions: {
535
+ toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush']
536
+ }
537
+ }
538
+ }, {
539
+ name: 'Shape',
540
+ type: 'radio',
541
+ id: 'eraser-mode',
542
+ value: 'ThresholdCircularBrush',
543
+ values: [{
544
+ value: 'ThresholdCircularBrush',
545
+ label: 'Circle'
546
+ }, {
547
+ value: 'ThresholdSphereBrush',
548
+ label: 'Sphere'
549
+ }],
550
+ commands: 'setToolActiveToolbar'
551
+ }, {
552
+ name: 'ThresholdRange',
553
+ type: 'double-range',
554
+ id: 'threshold-range',
555
+ min: 0,
556
+ max: 10,
557
+ step: 1,
558
+ values: [2, 5],
559
+ commands: {
560
+ commandName: 'setThresholdRange',
561
+ commandOptions: {
562
+ toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush']
563
+ }
564
+ }
565
+ }]
566
+ }]
567
+ }
568
+ }, {
569
+ id: 'Shapes',
570
+ uiType: 'ohif.radioGroup',
571
+ props: {
572
+ label: 'Shapes',
573
+ evaluate: {
574
+ name: 'evaluate.cornerstone.segmentation',
575
+ options: {
576
+ toolNames: ['CircleScissor', 'SphereScissor', 'RectangleScissor']
577
+ }
578
+ },
579
+ icon: 'icon-tool-shape',
580
+ commands: _createSetToolActiveCommands('CircleScissor'),
581
+ options: [{
582
+ name: 'Shape',
583
+ type: 'radio',
584
+ value: 'CircleScissor',
585
+ id: 'shape-mode',
586
+ values: [{
587
+ value: 'CircleScissor',
588
+ label: 'Circle'
589
+ }, {
590
+ value: 'SphereScissor',
591
+ label: 'Sphere'
592
+ }, {
593
+ value: 'RectangleScissor',
594
+ label: 'Rectangle'
595
+ }],
596
+ commands: 'setToolActiveToolbar'
597
+ }]
598
+ }
599
+ }];
600
+ /* harmony default export */ const segmentationButtons = (segmentationButtons_toolbarButtons);
601
+ ;// CONCATENATED MODULE: ../../../modes/preclinical-4d/src/index.tsx
602
+
603
+
604
+
605
+
606
+
607
+
608
+ const extensionDependencies = {
609
+ '@ohif/extension-default': '3.7.0-beta.76',
610
+ '@ohif/extension-cornerstone': '3.7.0-beta.76',
611
+ '@ohif/extension-cornerstone-dynamic-volume': '3.7.0-beta.76',
612
+ '@ohif/extension-cornerstone-dicom-seg': '3.7.0-beta.76',
613
+ '@ohif/extension-tmtv': '3.7.0-beta.76'
614
+ };
615
+ const ohif = {
616
+ layout: '@ohif/extension-default.layoutTemplateModule.viewerLayout',
617
+ defaultSopClassHandler: '@ohif/extension-default.sopClassHandlerModule.stack',
618
+ chartSopClassHandler: '@ohif/extension-default.sopClassHandlerModule.chart',
619
+ hangingProtocol: '@ohif/extension-default.hangingProtocolModule.default',
620
+ leftPanel: '@ohif/extension-default.panelModule.seriesList',
621
+ rightPanel: '@ohif/extension-default.panelModule.measure',
622
+ chartViewport: '@ohif/extension-default.viewportModule.chartViewport'
623
+ };
624
+ const src_dynamicVolume = {
625
+ leftPanel: '@ohif/extension-cornerstone-dynamic-volume.panelModule.dynamic-volume'
626
+ };
627
+ const src_cornerstone = {
628
+ viewport: '@ohif/extension-cornerstone.viewportModule.cornerstone',
629
+ activeViewportWindowLevel: '@ohif/extension-cornerstone.panelModule.activeViewportWindowLevel'
630
+ };
631
+ function modeFactory({
632
+ modeConfiguration
633
+ }) {
634
+ return {
635
+ id: id,
636
+ routeName: 'dynamic-volume',
637
+ displayName: '4D PT/CT',
638
+ onModeEnter: function ({
639
+ servicesManager,
640
+ extensionManager,
641
+ commandsManager
642
+ }) {
643
+ const {
644
+ measurementService,
645
+ toolbarService,
646
+ cineService,
647
+ cornerstoneViewportService,
648
+ toolGroupService,
649
+ customizationService,
650
+ viewportGridService
651
+ } = servicesManager.services;
652
+ const utilityModule = extensionManager.getModuleEntry('@ohif/extension-cornerstone.utilityModule.tools');
653
+ const {
654
+ toolNames,
655
+ Enums
656
+ } = utilityModule.exports;
657
+ measurementService.clearMeasurements();
658
+ initToolGroups({
659
+ toolNames,
660
+ Enums,
661
+ toolGroupService,
662
+ commandsManager
663
+ });
664
+ toolbarService.addButtons([...src_toolbarButtons, ...segmentationButtons]);
665
+ toolbarService.createButtonSection('secondary', ['ProgressDropdown']);
666
+
667
+ // the primary button section is created in the workflow steps
668
+ // specific to the step
669
+ customizationService.addModeCustomizations([{
670
+ id: 'segmentation.panel',
671
+ segmentationPanelMode: 'expanded',
672
+ addSegment: false,
673
+ onSegmentationAdd: () => {
674
+ commandsManager.run('createNewLabelmapFromPT');
675
+ }
676
+ }]);
677
+
678
+ // Auto play the clip initially when the volumes are loaded
679
+ const {
680
+ unsubscribe
681
+ } = cornerstoneViewportService.subscribe(cornerstoneViewportService.EVENTS.VIEWPORT_VOLUMES_CHANGED, () => {
682
+ const viewportId = viewportGridService.getActiveViewportId();
683
+ const csViewport = cornerstoneViewportService.getCornerstoneViewport(viewportId);
684
+ cineService.playClip(csViewport.element);
685
+ // cineService.setIsCineEnabled(true);
686
+
687
+ unsubscribe();
688
+ });
689
+ },
690
+ onSetupRouteComplete: ({
691
+ servicesManager
692
+ }) => {
693
+ // This needs to run after hanging protocol matching process because
694
+ // it may change the protocol/stage based on workflow stage settings
695
+ initWorkflowSteps({
696
+ servicesManager
697
+ });
698
+ },
699
+ onModeExit: ({
700
+ servicesManager
701
+ }) => {
702
+ const {
703
+ toolGroupService,
704
+ syncGroupService,
705
+ segmentationService,
706
+ cornerstoneViewportService
707
+ } = servicesManager.services;
708
+ toolGroupService.destroy();
709
+ syncGroupService.destroy();
710
+ segmentationService.destroy();
711
+ cornerstoneViewportService.destroy();
712
+ },
713
+ get validationTags() {
714
+ return {
715
+ study: [],
716
+ series: []
717
+ };
718
+ },
719
+ isValidMode: ({
720
+ modalities,
721
+ study
722
+ }) => {
723
+ // Todo: we need to find a better way to validate the mode
724
+ return {
725
+ valid: study.mrn === 'M1',
726
+ description: 'This mode is only available for 4D PET/CT studies.'
727
+ };
728
+ },
729
+ /**
730
+ * Mode Routes are used to define the mode's behavior. A list of Mode Route
731
+ * that includes the mode's path and the layout to be used. The layout will
732
+ * include the components that are used in the layout. For instance, if the
733
+ * default layoutTemplate is used (id: '@ohif/extension-default.layoutTemplateModule.viewerLayout')
734
+ * it will include the leftPanels, rightPanels, and viewports. However, if
735
+ * you define another layoutTemplate that includes a Footer for instance,
736
+ * you should provide the Footer component here too. Note: We use Strings
737
+ * to reference the component's ID as they are registered in the internal
738
+ * ExtensionManager. The template for the string is:
739
+ * `${extensionId}.{moduleType}.${componentId}`.
740
+ */
741
+ routes: [{
742
+ path: 'preclinical-4d',
743
+ layoutTemplate: ({
744
+ location,
745
+ servicesManager
746
+ }) => {
747
+ return {
748
+ id: ohif.layout,
749
+ props: {
750
+ leftPanels: [[src_dynamicVolume.leftPanel, src_cornerstone.activeViewportWindowLevel]],
751
+ rightPanels: [],
752
+ rightPanelClosed: true,
753
+ viewports: [{
754
+ namespace: src_cornerstone.viewport,
755
+ displaySetsToDisplay: [ohif.defaultSopClassHandler]
756
+ }, {
757
+ namespace: ohif.chartViewport,
758
+ displaySetsToDisplay: [ohif.chartSopClassHandler]
759
+ }]
760
+ }
761
+ };
762
+ }
763
+ }],
764
+ extensions: extensionDependencies,
765
+ // Default protocol gets self-registered by default in the init
766
+ hangingProtocol: 'default4D',
767
+ // Order is important in sop class handlers when two handlers both use
768
+ // the same sop class under different situations. In that case, the more
769
+ // general handler needs to come last. For this case, the dicomvideo must
770
+ // come first to remove video transfer syntax before ohif uses images
771
+ sopClassHandlers: [ohif.chartSopClassHandler, ohif.defaultSopClassHandler],
772
+ hotkeys: [...src/* hotkeys */.ot.defaults.hotkeyBindings]
773
+ };
774
+ }
775
+ const mode = {
776
+ id: id,
777
+ modeFactory,
778
+ extensionDependencies
779
+ };
780
+ /* harmony default export */ const preclinical_4d_src = (mode);
781
+
782
+ /***/ })
783
+
784
+ }]);