Simone
(Simone)
November 11, 2021, 10:07am
1
Hi Everyone,
I’m trying to develop a browser side js that can read a folder (chosen by the user) and detect/regroup all the dicom series in it. Is it possible in vtk.js? I know that in standard vtk library this could be achieved using vtkDICOMDirectory, while this function is missing in vtk.js.
Thanks in advance, any help would be appreciated.
Forrest
(Forrest)
November 11, 2021, 3:11pm
2
Hi, you can use itk.js to read in the DICOM into vtk.js. Check out the itk.js documentation to get more info on what you want to achieve.
1 Like
Simone
(Simone)
November 12, 2021, 10:20am
3
Thank you!
Do you also know if using itk.js/vtk.js i could achieve anonymization/deidentification?
pieper
(Steve Pieper)
November 12, 2021, 3:06pm
4
You could have a look at this project:
Proof of concept DICOM decompress and anonymize in browser, writing new P10 file - GitHub - jmhmd/dicom-browser-anonymize: Proof of concept DICOM decompress and anonymize in browser, writing new P1...
1 Like
rajajms
(Raja Malakar)
July 19, 2023, 11:41am
5
Though your question is different, but if you want to load and perse dicom images
async function handleFile(event) {
const files = event.target.files;
const { image, webWorker } = await window.itk.readImageDICOMFileSeries(files, false);
webWorker.terminate();
const vtkImage = vtkITKHelper.convertItkToVtkImage(image);
}
const dicomFileInput = document.getElementById('dicomFileInput');
dicomFileInput.addEventListener('change', handleFile);
make sure to import ITKHelper as below and also itk-wasm
import vtkITKHelper from '@kitware/vtk.js/Common/DataModel/ITKHelper';