Mercurial > hg > orthanc-stone
comparison 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 |
comparison
equal
deleted
inserted
replaced
1123:45df56448b2a | 1141:7681f3943748 |
---|---|
58 float defaultWindowingWidth_; | 58 float defaultWindowingWidth_; |
59 Orthanc::PixelFormat expectedPixelFormat_; | 59 Orthanc::PixelFormat expectedPixelFormat_; |
60 bool hasIndexInSeries_; | 60 bool hasIndexInSeries_; |
61 unsigned int indexInSeries_; | 61 unsigned int indexInSeries_; |
62 std::string doseUnits_; | 62 std::string doseUnits_; |
63 double doseGridScaling_; | |
63 | 64 |
64 void ComputeDoseOffsets(const Orthanc::DicomMap& dicom); | 65 void ComputeDoseOffsets(const Orthanc::DicomMap& dicom); |
65 | 66 |
66 Data(const Orthanc::DicomMap& dicom); | 67 Data(const Orthanc::DicomMap& dicom); |
67 | 68 |
68 CoordinateSystem3D GetFrameGeometry(unsigned int frame) const; | 69 CoordinateSystem3D GetFrameGeometry(unsigned int frame) const; |
69 | 70 |
70 bool IsPlaneWithinSlice(unsigned int frame, | 71 bool IsPlaneWithinSlice(unsigned int frame, |
71 const CoordinateSystem3D& plane) const; | 72 const CoordinateSystem3D& plane) const; |
72 | 73 |
73 void ApplyRescale(Orthanc::ImageAccessor& image, | 74 void ApplyRescaleAndDoseScaling( |
74 bool useDouble) const; | 75 Orthanc::ImageAccessor& image, bool useDouble) const; |
75 }; | 76 }; |
76 | 77 |
77 | 78 |
78 Data data_; | 79 Data data_; |
79 | 80 |
203 | 204 |
204 const std::string& GetDoseUnits() const | 205 const std::string& GetDoseUnits() const |
205 { | 206 { |
206 return data_.doseUnits_; | 207 return data_.doseUnits_; |
207 } | 208 } |
209 | |
210 double GetDoseGridScaling() const | |
211 { | |
212 return data_.doseGridScaling_; | |
213 } | |
208 }; | 214 }; |
209 } | 215 } |