Fix contour annotations RTSS saving (#5545)
* [WIP] Fix contour annotations RTSS saving * fix: Export image sop image reference provider * Fixes for download with filename * Updates to fix metadata issues with CS3D * Updates to save menu * Fixing some additional re-save metadata * Add support for saving with predecessor image sequence * PR comment fixes * fix: Load RTSS after save * fix segmentation save * fix load of mixed seg/rt studies * Use frame module to get information on the frame shown * Fix study browser to use instances.length when numImageFrames not present * fix: Load of display set split from multiple non-FOR referenes * Fix RT and SEG applying to wrong series because of using referenced series sequence without checkout sop instances * Fix save seg * Update to released CS3D versions * test: Add revokeObjectURL to test download blob * Add hard dependency on mode-basic to fix build order issues * fix: build * Try to fix build segmentation * PR comments * PR comment update
This commit is contained in:
1 parent
9c5043ca2c
commit
57205703bb
68 files changed
+962
-648
No files matched your search
@@ -42,8 +42,8 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@babel/runtime": "7.28.2",
|
||||
"@cornerstonejs/core": "4.11.2",
|
||||
"@cornerstonejs/tools": "4.11.2",
|
||||
"@cornerstonejs/core": "4.11.3",
|
||||
"@cornerstonejs/tools": "4.11.3",
|
||||
"@ohif/core": "3.12.0-beta.90",
|
||||
"@ohif/extension-cornerstone": "3.12.0-beta.90",
|
||||
"@ohif/extension-default": "3.12.0-beta.90",
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
import { UltrasoundPleuraBLineTool, Enums as csToolsEnums } from '@cornerstonejs/tools';
|
||||
import { Types as OhifTypes } from '@ohif/core';
|
||||
import { Types as OhifTypes, utils } from '@ohif/core';
|
||||
import { eventTarget, triggerEvent, utilities } from '@cornerstonejs/core';
|
||||
import getInstanceByImageId from './getInstanceByImageId';
|
||||
import { setShowPercentage } from './PleuraBlinePercentage';
|
||||
|
||||
const { downloadBlob } = utils;
|
||||
|
||||
const { transformWorldToIndex } = utilities;
|
||||
|
||||
/**
|
||||
@@ -13,7 +15,6 @@ const { transformWorldToIndex } = utilities;
|
||||
*/
|
||||
function commandsModule({
|
||||
servicesManager,
|
||||
commandsManager,
|
||||
}: OhifTypes.Extensions.ExtensionParams): OhifTypes.Extensions.CommandsModule {
|
||||
const { viewportGridService, toolGroupService, cornerstoneViewportService } =
|
||||
servicesManager.services as AppTypes.Services;
|
||||
@@ -275,14 +276,9 @@ function commandsModule({
|
||||
|
||||
// Create a blob with the JSON data
|
||||
const blob = new Blob([jsonString], { type: 'application/json' });
|
||||
|
||||
// Create a URL for the blob
|
||||
const url = URL.createObjectURL(blob);
|
||||
|
||||
// Create an anchor element
|
||||
const a = document.createElement('a');
|
||||
a.href = url;
|
||||
a.download = `ultrasound_annotations_${new Date().toISOString().slice(0, 10)}.json`;
|
||||
downloadBlob(blob, {
|
||||
filename: `ultrasound_annotations_${new Date().toISOString().slice(0, 10)}.json`,
|
||||
});
|
||||
|
||||
// Append to the document, click to download, and remove
|
||||
document.body.appendChild(a);
|
||||
|
||||
Reference in new issue
Block a user