Mercurial > hg > orthanc-stone
diff Framework/Toolbox/DicomInstanceParameters.h @ 1141:7681f3943748
Changed handling of DoseGridScaling: before this commit, rescaleSlope was set to
the DoseGridScaling value if rescale* tags weren't present AND in the case of a
dose. This caused issues in dose files where all three tags (DoseGridScaling,
RescaleSlope and RescaleIntercept) were present, which previously led to the
DoseGridScaling tag to be ignored. Now, the rescale* tags are *ignored* in dose
files and DoseGridScaling is always taken into account.
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Fri, 08 Nov 2019 14:25:35 +0100 |
parents | 5a18e6a395bc |
children | acb399643945 2d8ab34c8c91 |
line wrap: on
line diff
--- a/Framework/Toolbox/DicomInstanceParameters.h Tue Nov 05 18:26:59 2019 +0100 +++ b/Framework/Toolbox/DicomInstanceParameters.h Fri Nov 08 14:25:35 2019 +0100 @@ -60,6 +60,7 @@ bool hasIndexInSeries_; unsigned int indexInSeries_; std::string doseUnits_; + double doseGridScaling_; void ComputeDoseOffsets(const Orthanc::DicomMap& dicom); @@ -70,8 +71,8 @@ bool IsPlaneWithinSlice(unsigned int frame, const CoordinateSystem3D& plane) const; - void ApplyRescale(Orthanc::ImageAccessor& image, - bool useDouble) const; + void ApplyRescaleAndDoseScaling( + Orthanc::ImageAccessor& image, bool useDouble) const; }; @@ -205,5 +206,10 @@ { return data_.doseUnits_; } + + double GetDoseGridScaling() const + { + return data_.doseGridScaling_; + } }; }