comparison Framework/Inputs/DicomPyramidLevel.h @ 56:83cd735c885d

speedup the loading of DICOM sources
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 24 Nov 2016 15:41:21 +0100
parents b6432a00b103
children 91fc9583b2de
comparison
equal deleted inserted replaced
55:b6432a00b103 56:83cd735c885d
29 class DicomPyramidLevel : public boost::noncopyable 29 class DicomPyramidLevel : public boost::noncopyable
30 { 30 {
31 private: 31 private:
32 struct TileContent 32 struct TileContent
33 { 33 {
34 const DicomPyramidInstance* instance_; 34 DicomPyramidInstance* instance_;
35 unsigned int frame_; 35 unsigned int frame_;
36 36
37 TileContent() : 37 TileContent() :
38 instance_(NULL), 38 instance_(NULL),
39 frame_(0) 39 frame_(0)
40 { 40 {
50 std::vector<TileContent> tiles_; 50 std::vector<TileContent> tiles_;
51 51
52 TileContent& GetTileContent(unsigned int tileX, 52 TileContent& GetTileContent(unsigned int tileX,
53 unsigned int tileY); 53 unsigned int tileY);
54 54
55 void RegisterFrame(const DicomPyramidInstance& instance, 55 void RegisterFrame(DicomPyramidInstance& instance,
56 unsigned int frame); 56 unsigned int frame);
57 57
58 bool LookupTile(TileContent& tile, 58 bool LookupTile(TileContent& tile,
59 unsigned int tileX, 59 unsigned int tileX,
60 unsigned int tileY) const; 60 unsigned int tileY) const;
61 61
62 public: 62 public:
63 DicomPyramidLevel(const DicomPyramidInstance& instance); 63 DicomPyramidLevel(DicomPyramidInstance& instance);
64 64
65 void AddInstance(const DicomPyramidInstance& instance); 65 void AddInstance(DicomPyramidInstance& instance);
66 66
67 unsigned int GetTotalWidth() const 67 unsigned int GetTotalWidth() const
68 { 68 {
69 return totalWidth_; 69 return totalWidth_;
70 } 70 }