comparison OrthancStone/Sources/Loaders/SeriesFramesLoader.cpp @ 1564:e731e62692a9

upgrading Orthanc framework
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 17 Sep 2020 15:18:21 +0200
parents 244ad1e4e76a
children 85e117739eca
comparison
equal deleted inserted replaced
1563:e0045462a25c 1564:e731e62692a9
23 23
24 #include "../Oracle/ParseDicomFromFileCommand.h" 24 #include "../Oracle/ParseDicomFromFileCommand.h"
25 #include "../Oracle/ParseDicomFromWadoCommand.h" 25 #include "../Oracle/ParseDicomFromWadoCommand.h"
26 26
27 #if ORTHANC_ENABLE_DCMTK == 1 27 #if ORTHANC_ENABLE_DCMTK == 1
28 # include <DicomParsing/Internals/DicomImageDecoder.h> 28 # include <DicomParsing/ParsedDicomFile.h>
29 #endif 29 #endif
30 30
31 #include <DicomFormat/DicomInstanceHasher.h> 31 #include <DicomFormat/DicomInstanceHasher.h>
32 #include <Images/Image.h> 32 #include <Images/Image.h>
33 #include <Images/ImageProcessing.h> 33 #include <Images/ImageProcessing.h>
168 Orthanc::ParsedDicomFile& dicom) 168 Orthanc::ParsedDicomFile& dicom)
169 { 169 {
170 size_t frameIndex = frames_.GetFrameIndex(payload.GetSeriesIndex()); 170 size_t frameIndex = frames_.GetFrameIndex(payload.GetSeriesIndex());
171 171
172 std::unique_ptr<Orthanc::ImageAccessor> decoded; 172 std::unique_ptr<Orthanc::ImageAccessor> decoded;
173 decoded.reset(Orthanc::DicomImageDecoder::Decode( 173 decoded.reset(dicom.DecodeFrame(static_cast<unsigned int>(frameIndex)));
174 dicom,
175 static_cast<unsigned int>(frameIndex)));
176 174
177 if (decoded.get() == NULL) 175 if (decoded.get() == NULL)
178 { 176 {
179 throw Orthanc::OrthancException(Orthanc::ErrorCode_NullPointer); 177 throw Orthanc::OrthancException(Orthanc::ErrorCode_NullPointer);
180 } 178 }