vtk-dicom
vtk-dicom copied to clipboard
Converting real-valued pixel data to integer data
In other words, perform the reverse of what vtkDICOMApplyRescale does, with a filter called (for example) vtkDICOMCreateRescale. It should examine the data, and decide on a good scale factor to fit the data into either short or unsigned short, and generate the meta data. For CT, it will add RescaleSlope and RescaleIntercept. For MR, it will add the real world value mapping sequence.
Two big difficulties: 1) the input data might not have a vtkDICOMMetaData object to be added to, and 2) the attributes go in different places in enhanced files vs. legacy files.
The filter needs to know what IOD is being built, just like the vtkDICOMGenerator. This makes me wonder if maybe the filter is unnecessary, and the conversion from real values should be the responsibility of the generator.
Also for PET dataset it should compute a per instance rescale slope/intercept to cope with the dynamic range.
Yes, but vtk-dicom can't even write PET data yet!