Mercurial > hg > orthanc-stone
annotate Framework/Toolbox/ParallelSlices.h @ 135:e2fe9352f240 wasm
upgrade to year 2018
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 02 Jan 2018 09:56:08 +0100 |
parents | 53025eecbc95 |
children | fccffbf99ba1 |
rev | line source |
---|---|
0 | 1 /** |
2 * Stone of Orthanc | |
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics | |
4 * Department, University Hospital of Liege, Belgium | |
135
e2fe9352f240
upgrade to year 2018
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
110
diff
changeset
|
5 * Copyright (C) 2017-2018 Osimis S.A., Belgium |
0 | 6 * |
7 * This program is free software: you can redistribute it and/or | |
47 | 8 * modify it under the terms of the GNU Affero General Public License |
9 * as published by the Free Software Foundation, either version 3 of | |
10 * the License, or (at your option) any later version. | |
0 | 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 | |
47 | 14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
15 * Affero General Public License for more details. | |
16 * | |
17 * You should have received a copy of the GNU Affero General Public License | |
0 | 18 * along with this program. If not, see <http://www.gnu.org/licenses/>. |
19 **/ | |
20 | |
21 | |
22 #pragma once | |
23 | |
110
53025eecbc95
renamed SliceGeometry as CoordinateSystem3D
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
53
diff
changeset
|
24 #include "CoordinateSystem3D.h" |
0 | 25 |
26 namespace OrthancStone | |
27 { | |
53
c2dc924f1a63
removing threading out of the framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
47
diff
changeset
|
28 class ParallelSlices : public boost::noncopyable |
0 | 29 { |
30 private: | |
110
53025eecbc95
renamed SliceGeometry as CoordinateSystem3D
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
53
diff
changeset
|
31 Vector normal_; |
53025eecbc95
renamed SliceGeometry as CoordinateSystem3D
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
53
diff
changeset
|
32 std::vector<CoordinateSystem3D*> slices_; |
0 | 33 |
34 ParallelSlices& operator= (const ParallelSlices& other); // Forbidden | |
35 | |
36 public: | |
37 ParallelSlices(); | |
38 | |
39 ParallelSlices(const ParallelSlices& other); | |
40 | |
41 ~ParallelSlices(); | |
42 | |
43 const Vector& GetNormal() const | |
44 { | |
45 return normal_; | |
46 } | |
47 | |
110
53025eecbc95
renamed SliceGeometry as CoordinateSystem3D
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
53
diff
changeset
|
48 void AddSlice(const CoordinateSystem3D& slice); |
0 | 49 |
50 void AddSlice(const Vector& origin, | |
51 const Vector& axisX, | |
52 const Vector& axisY); | |
53 | |
54 size_t GetSliceCount() const | |
55 { | |
56 return slices_.size(); | |
57 } | |
58 | |
110
53025eecbc95
renamed SliceGeometry as CoordinateSystem3D
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
53
diff
changeset
|
59 const CoordinateSystem3D& GetSlice(size_t index) const; |
0 | 60 |
61 bool ComputeClosestSlice(size_t& closestSlice, | |
62 double& closestDistance, | |
63 const Vector& origin) const; | |
64 | |
65 ParallelSlices* Reverse() const; | |
66 }; | |
67 } |