Mercurial > hg > orthanc-stone
annotate OrthancStone/Sources/Loaders/DicomStructureSetLoader.h @ 1741:62377949e739
todo
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 19 Jan 2021 16:12:43 +0100 |
parents | 9ac2a65d4172 |
children | 3889ae96d2e9 |
rev | line source |
---|---|
815 | 1 /** |
2 * Stone of Orthanc | |
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics | |
4 * Department, University Hospital of Liege, Belgium | |
1739
9ac2a65d4172
upgrade to year 2021
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1640
diff
changeset
|
5 * Copyright (C) 2017-2021 Osimis S.A., Belgium |
815 | 6 * |
7 * This program is free software: you can redistribute it and/or | |
1598
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
8 * modify it under the terms of the GNU Lesser General Public License |
815 | 9 * as published by the Free Software Foundation, either version 3 of |
10 * the License, or (at your option) any later version. | |
11 * | |
12 * This program is distributed in the hope that it will be useful, but | |
13 * WITHOUT ANY WARRANTY; without even the implied warranty of | |
1598
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
15 * Lesser General Public License for more details. |
1596
4fb8fdf03314
removed annoying whitespace
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1571
diff
changeset
|
16 * |
1598
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
17 * You should have received a copy of the GNU Lesser General Public |
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
18 * License along with this program. If not, see |
8563ea5d8ae4
relicensing some files, cf. osimis bm26 and chu agreement on 2020-05-20
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1596
diff
changeset
|
19 * <http://www.gnu.org/licenses/>. |
815 | 20 **/ |
21 | |
22 | |
23 #pragma once | |
24 | |
1339
556b4bc19118
The loaders have been adapter to the nobroker architecture
Benjamin Golinvaux <bgo@osimis.io>
parents:
1337
diff
changeset
|
25 #include "../Toolbox/DicomStructureSet.h" |
556b4bc19118
The loaders have been adapter to the nobroker architecture
Benjamin Golinvaux <bgo@osimis.io>
parents:
1337
diff
changeset
|
26 #include "../Volumes/IVolumeSlicer.h" |
556b4bc19118
The loaders have been adapter to the nobroker architecture
Benjamin Golinvaux <bgo@osimis.io>
parents:
1337
diff
changeset
|
27 #include "../Loaders/ILoadersContext.h" |
815 | 28 #include "LoaderStateMachine.h" |
29 | |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
30 #include <vector> |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
31 |
1337
b1396be5aa27
Moved the fixed loaders back from the dead
Benjamin Golinvaux <bgo@osimis.io>
parents:
1314
diff
changeset
|
32 namespace OrthancStone |
815 | 33 { |
34 class DicomStructureSetLoader : | |
35 public LoaderStateMachine, | |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
36 public IVolumeSlicer, |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
37 public IObservable |
815 | 38 { |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
39 public: |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
40 ORTHANC_STONE_DEFINE_ORIGIN_MESSAGE(__FILE__, __LINE__, StructuresReady, DicomStructureSetLoader); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
41 ORTHANC_STONE_DEFINE_ORIGIN_MESSAGE(__FILE__, __LINE__, StructuresUpdated, DicomStructureSetLoader); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
42 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
43 /** |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
44 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
45 Once the structure set has been loaded (the LoadStructure state), we need to fill it with geometry information |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
46 from the referenced slices (tag (0008,1155) described here: |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
47 https://dicom.innolitics.com/ciods/rt-structure-set/general-reference/00081140/00081155 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
48 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
49 This interface allows to customize how this information can be gathered. By default, the RestInstanceLookupHandler |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
50 will perform a REST call to the Orthanc API to retrieve this information. |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
51 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
52 Injecting another implementation of this interface is useful when where this information can be supplied in |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
53 another (faster) way (for instance, if a separate loader for the CT series can be used to supply the slice geometry) |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
54 */ |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
55 class IInstanceLookupHandler |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
56 { |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
57 public: |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
58 virtual void RetrieveReferencedSlices(const std::set<std::string>& instances) = 0; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
59 }; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
60 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
61 // predeclaration of the default IInstanceLookupHandler implementation |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
62 class RestInstanceLookupHandler; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
63 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
64 static boost::shared_ptr<DicomStructureSetLoader> Create( |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
65 ILoadersContext& loadersContext); |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
66 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
67 void SetInstanceLookupHandler(boost::shared_ptr<IInstanceLookupHandler> instanceLookupHandler) |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
68 { |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
69 instanceLookupHandler_ = instanceLookupHandler; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
70 } |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
71 |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
72 DicomStructureSet* GetContent() |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
73 { |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
74 return content_.get(); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
75 } |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
76 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
77 void SetStructureDisplayState(size_t structureIndex, bool display); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
78 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
79 bool GetStructureDisplayState(size_t structureIndex) const |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
80 { |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
81 return structureVisibility_.at(structureIndex); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
82 } |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
83 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
84 ~DicomStructureSetLoader(); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
85 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
86 void LoadInstance(const std::string& instanceId, |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
87 const std::vector<std::string>& initiallyVisibleStructures = std::vector<std::string>()); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
88 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
89 void LoadInstanceFullVisibility(const std::string& instanceId); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
90 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
91 |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
92 virtual IExtractedSlice* ExtractSlice(const CoordinateSystem3D& cuttingPlane) ORTHANC_OVERRIDE; |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
93 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
94 void SetStructuresReady(); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
95 void SetStructuresUpdated(); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
96 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
97 bool AreStructuresReady() const; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
98 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
99 /** |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
100 Called by the IInstanceLookupHandler when slice referenced instance information is available. |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
101 When the last referenced slice is received, this method will perform a final check and will warn observers |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
102 */ |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
103 void AddReferencedSlice(const Orthanc::DicomMap& dicom); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
104 |
815 | 105 private: |
106 class Slice; | |
107 | |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
108 // Only state of LoaderStateMachine |
815 | 109 class LoadStructure; // 1st state |
110 | |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
111 ILoadersContext& loadersContext_; |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
112 std::unique_ptr<DicomStructureSet> content_; |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
113 uint64_t revision_; |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
114 std::string instanceId_; |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
115 unsigned int countProcessedInstances_; |
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
116 unsigned int countReferencedInstances_; |
937
86ac61a040c9
Added getters and notifications to allow clients of the loaders (DicomStructureSetLoader, OrthancSeriesVolumeProgressiveLoader and OrthancMultiframeVolumeLoader) to know when the loading is finished + added ability for SDL event loop to execute a callback repeatedly (used to check the view loading state)
Benjamin Golinvaux <bgo@osimis.io>
parents:
935
diff
changeset
|
117 |
86ac61a040c9
Added getters and notifications to allow clients of the loaders (DicomStructureSetLoader, OrthancSeriesVolumeProgressiveLoader and OrthancMultiframeVolumeLoader) to know when the loading is finished + added ability for SDL event loop to execute a callback repeatedly (used to check the view loading state)
Benjamin Golinvaux <bgo@osimis.io>
parents:
935
diff
changeset
|
118 // will be set to true once the loading is finished |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
119 bool structuresReady_; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
120 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
121 /** |
1030
7014c2397b45
Empty structureNames now means NOTHING will be (initially) displayed
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
122 At load time, these strings are used to initialize the structureVisibility_ |
7014c2397b45
Empty structureNames now means NOTHING will be (initially) displayed
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
123 vector. |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
124 |
1030
7014c2397b45
Empty structureNames now means NOTHING will be (initially) displayed
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
125 As a special case, if initiallyVisibleStructures_ contains a single string |
7014c2397b45
Empty structureNames now means NOTHING will be (initially) displayed
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
126 that is '*', ALL structures will be made visible. |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
127 */ |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
128 std::vector<std::string> initiallyVisibleStructures_; |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
129 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
130 /** |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
131 Contains the "Should this structure be displayed?" flag for all structures. |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
132 Only filled when structures are loaded. |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
133 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
134 Changing this value directly affects the rendering |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
135 */ |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
136 std::vector<bool> structureVisibility_; |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1000
diff
changeset
|
137 |
1416
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
138 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
139 boost::shared_ptr<IInstanceLookupHandler> instanceLookupHandler_; |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
140 |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
141 private: |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
142 void RetrieveReferencedSlices(const std::set<std::string>& nonEmptyInstances); |
d959bc8f6c1b
Instance lookup is now performed in a separate class through an interface. Another implementation can be injected (SetInstanceLookupHandler)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1385
diff
changeset
|
143 |
1314
9b126de2cde2
Since the observer system now uses shared_ptr and many registrations are
Benjamin Golinvaux <bgo@osimis.io>
parents:
1310
diff
changeset
|
144 protected: |
1640
52b8b96cb55f
cleaning namespaces
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1598
diff
changeset
|
145 explicit DicomStructureSetLoader(ILoadersContext& loadersContext); |
815 | 146 }; |
147 } |