comparison Framework/Volumes/ImageBuffer3D.h @ 1298:8a0a62189f46

replacing std::auto_ptr by std::unique_ptr
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 02 Mar 2020 16:31:30 +0100
parents 2d8ab34c8c91
children 30deba7bc8e2
comparison
equal deleted inserted replaced
1296:86400fa16091 1298:8a0a62189f46
22 #pragma once 22 #pragma once
23 23
24 #include "../StoneEnumerations.h" 24 #include "../StoneEnumerations.h"
25 #include "../Toolbox/LinearAlgebra.h" 25 #include "../Toolbox/LinearAlgebra.h"
26 26
27 #include <Core/Compatibility.h>
27 #include <Core/Images/Image.h> 28 #include <Core/Images/Image.h>
28 29
29 namespace OrthancStone 30 namespace OrthancStone
30 { 31 {
31 class ImageBuffer3D : public boost::noncopyable 32 class ImageBuffer3D : public boost::noncopyable
141 142
142 class SliceReader : public boost::noncopyable 143 class SliceReader : public boost::noncopyable
143 { 144 {
144 private: 145 private:
145 Orthanc::ImageAccessor accessor_; 146 Orthanc::ImageAccessor accessor_;
146 std::auto_ptr<Orthanc::Image> sagittal_; // Unused for axial and coronal 147 std::unique_ptr<Orthanc::Image> sagittal_; // Unused for axial and coronal
147 148
148 public: 149 public:
149 SliceReader(const ImageBuffer3D& that, 150 SliceReader(const ImageBuffer3D& that,
150 VolumeProjection projection, 151 VolumeProjection projection,
151 unsigned int slice); 152 unsigned int slice);
161 { 162 {
162 private: 163 private:
163 ImageBuffer3D& that_; 164 ImageBuffer3D& that_;
164 bool modified_; 165 bool modified_;
165 Orthanc::ImageAccessor accessor_; 166 Orthanc::ImageAccessor accessor_;
166 std::auto_ptr<Orthanc::Image> sagittal_; // Unused for axial and coronal 167 std::unique_ptr<Orthanc::Image> sagittal_; // Unused for axial and coronal
167 168
168 void Flush(); 169 void Flush();
169 170
170 public: 171 public:
171 SliceWriter(ImageBuffer3D& that, 172 SliceWriter(ImageBuffer3D& that,