Mercurial > hg > orthanc-stone
annotate OrthancStone/UnitTestsSources/TestStructureSet.cpp @ 1895:14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 19 Jan 2022 14:51:55 +0100 |
parents | 438071a29f77 |
children | affde38b84de |
rev | line source |
---|---|
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1 /** |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
2 * Stone of Orthanc |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
4 * Department, University Hospital of Liege, Belgium |
1871
7053b8a0aaec
upgrade to year 2022
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1870
diff
changeset
|
5 * Copyright (C) 2017-2022 Osimis S.A., Belgium |
7053b8a0aaec
upgrade to year 2022
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1870
diff
changeset
|
6 * Copyright (C) 2021-2022 Sebastien Jodogne, ICTEAM UCLouvain, Belgium |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
7 * |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
8 * This program is free software: you can redistribute it and/or |
1877
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
9 * modify it under the terms of the GNU Lesser General Public License |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
10 * as published by the Free Software Foundation, either version 3 of |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
11 * the License, or (at your option) any later version. |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
12 * |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
13 * This program is distributed in the hope that it will be useful, but |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
14 * WITHOUT ANY WARRANTY; without even the implied warranty of |
1877
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
16 * Lesser General Public License for more details. |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
17 * |
1877
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
18 * You should have received a copy of the GNU Lesser General Public |
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
19 * License along with this program. If not, see |
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
20 * <http://www.gnu.org/licenses/>. |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
21 **/ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
22 |
1877
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
23 |
1120
11b7785dd01b
This cpp file leads the optimizer bugging off out of the Solar System
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
24 // working around a bug where the Visual C++ compiler would get |
11b7785dd01b
This cpp file leads the optimizer bugging off out of the Solar System
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
25 // stuck trying to compile this cpp file in release mode |
11b7785dd01b
This cpp file leads the optimizer bugging off out of the Solar System
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
26 // (versions: https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B) |
1122
1b47659f6a9f
Fix ico uninitialized macro (expands to 0 and screws up test)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1120
diff
changeset
|
27 #ifdef _MSC_VER |
1123
45df56448b2a
Changed my mind to cover all msvc (after all it's a test)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1122
diff
changeset
|
28 # pragma optimize("", off) |
1122
1b47659f6a9f
Fix ico uninitialized macro (expands to 0 and screws up test)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1120
diff
changeset
|
29 // warning C4748: /GS can not protect parameters and local variables from |
1b47659f6a9f
Fix ico uninitialized macro (expands to 0 and screws up test)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1120
diff
changeset
|
30 // local buffer overrun because optimizations are disabled in function |
1123
45df56448b2a
Changed my mind to cover all msvc (after all it's a test)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1122
diff
changeset
|
31 # pragma warning(disable: 4748) |
1120
11b7785dd01b
This cpp file leads the optimizer bugging off out of the Solar System
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
32 #endif |
11b7785dd01b
This cpp file leads the optimizer bugging off out of the Solar System
Benjamin Golinvaux <bgo@osimis.io>
parents:
1019
diff
changeset
|
33 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
34 #include "../Sources/Toolbox/DicomStructureSet.h" |
1877
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
35 #include "../Sources/Toolbox/DicomStructureSet2.h" |
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
36 #include "../Sources/Toolbox/DicomStructureSetUtils.h" |
a2955abe4c2e
skeleton for the RenderingPlugin
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1871
diff
changeset
|
37 #include "../Sources/Toolbox/DisjointDataSet.h" |
1418
4e7751a4b603
Added a test for loader injection (basic "no regression" test). DISABLED_ because it requires a running Orthanc with a well-defined structure set instance.
Benjamin Golinvaux <bgo@osimis.io>
parents:
1279
diff
changeset
|
38 |
1880
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
39 #include <EmbeddedResources.h> |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
40 |
1453
2a11bbf7f6b0
trying to fix ubuntu 16.04 build
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1450
diff
changeset
|
41 #include <boost/date_time/posix_time/posix_time.hpp> |
1454
faaff0a1711e
fix for ubuntu 16.04
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1453
diff
changeset
|
42 #include <boost/make_shared.hpp> |
1418
4e7751a4b603
Added a test for loader injection (basic "no regression" test). DISABLED_ because it requires a running Orthanc with a well-defined structure set instance.
Benjamin Golinvaux <bgo@osimis.io>
parents:
1279
diff
changeset
|
43 |
1455
30deba7bc8e2
simplifying include_directories
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1454
diff
changeset
|
44 #include <gtest/gtest.h> |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
45 #include <string> |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
46 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
47 using namespace OrthancStone; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
48 |
1880
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
49 static const double DELTA_MAX = 10.0 * std::numeric_limits<float>::epsilon(); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
50 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
51 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
52 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
53 #define STONE_ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
54 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
55 #ifdef BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
56 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
57 static void CheckGroundTruth( |
1834
126522623e20
replaced OrthancStone::DicomPath by new class Orthanc::DicomPath from orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1742
diff
changeset
|
58 const std::vector<DicomStructure2>& structures, |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
59 const size_t structureIndex, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
60 const size_t sliceIndex, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
61 std::vector<double> groundTruth) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
62 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
63 const std::vector<DicomStructurePolygon2>& polygonsForThisStruct = structures.at(structureIndex).GetPolygons(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
64 const DicomStructurePolygon2& polygon = polygonsForThisStruct.at(sliceIndex); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
65 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
66 //double groundTruth[] = { 7.657838, 108.2725, 304.01, 6.826687, 107.4413, 304.01, 6.152492, 106.4785, 304.01, 5.655735, 105.4132, 304.01, 5.351513, 104.2778, 304.01, 5.249068, 103.1069, 304.01, 5.351513, 101.9359, 304.01, 5.655735, 100.8005, 304.01, 6.152492, 99.73524, 304.01, 6.826687, 98.77239, 304.01, 7.657838, 97.94124, 304.01, 8.620689, 97.26704, 304.01, 9.685987, 96.77029, 304.01, 10.82136, 96.46606, 304.01, 11.99231, 96.36362, 304.01, 13.16326, 96.46606, 304.01, 14.29864, 96.77029, 304.01, 15.36393, 97.26704, 304.01, 16.32678, 97.94124, 304.01, 17.15794, 98.77239, 304.01, 17.83213, 99.73524, 304.01, 18.32889, 100.8005, 304.01, 18.63311, 101.9359, 304.01, 18.73555, 103.1069, 304.01, 18.63311, 104.2778, 304.01, 18.32889, 105.4132, 304.01, 17.83213, 106.4785, 304.01, 17.15794, 107.4413, 304.01, 16.32678, 108.2725, 304.01, 15.36393, 108.9467, 304.01, 14.29864, 109.4434, 304.01, 13.16326, 109.7477, 304.01, 11.99231, 109.8501, 304.01, 10.82136, 109.7477, 304.01, 9.685987, 109.4434, 304.01, 8.620689, 108.9467, 304.01 }; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
67 size_t groundTruthItems = groundTruth.size(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
68 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
69 size_t pointCount = 3 * polygon.GetPointCount(); |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
70 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
71 EXPECT_EQ(groundTruthItems, pointCount); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
72 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
73 for (size_t i = 0; i < polygon.GetPointCount(); ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
74 { |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
75 const Vector& point = polygon.GetPoint(i); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
76 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
77 // loop over X, Y then Z. |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
78 for (size_t j = 0; j < 3; ++j) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
79 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
80 size_t index = 3 * i + j; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
81 ASSERT_LT(index, groundTruthItems); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
82 bool isNear = LinearAlgebra::IsNear(groundTruth[index], point[j]); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
83 EXPECT_TRUE(isNear); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
84 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
85 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
86 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
87 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
88 |
1837 | 89 #include <Toolbox.h> |
90 | |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
91 TEST(StructureSet2, ReadFromJsonThatsAll) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
92 { |
1880
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
93 /* |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
94 The "RT_STRUCT_00" string is the reply to the following Orthanc request: |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
95 |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
96 http://localhost:8042/instances/1aa5f84b-c32a03b4-3c1857da-da2e69f3-3ef6e2b3/tags?ignore-length=3006-0050 |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
97 |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
98 The tag hierarchy can be found here: https://dicom.innolitics.com/ciods/rt-dose |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
99 */ |
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
100 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
101 DicomStructureSet2 structureSet; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
102 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
103 FullOrthancDataset dicom(Orthanc::EmbeddedResources::GetFileResourceBuffer(Orthanc::EmbeddedResources::RT_STRUCT_00), |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
104 Orthanc::EmbeddedResources::GetFileResourceSize(Orthanc::EmbeddedResources::RT_STRUCT_00)); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
105 structureSet.Clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
106 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
107 structureSet.FillStructuresFromDataset(dicom); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
108 structureSet.ComputeDependentProperties(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
109 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
110 const std::vector<DicomStructure2>& structures = structureSet.structures_; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
111 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
112 /* |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
113 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
114 ██████╗ █████╗ ███████╗██╗ ██████╗ ██████╗██╗ ██╗███████╗ ██████╗██╗ ██╗███████╗ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
115 ██╔══██╗██╔══██╗██╔════╝██║██╔════╝ ██╔════╝██║ ██║██╔════╝██╔════╝██║ ██╔╝██╔════╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
116 ██████╔╝███████║███████╗██║██║ ██║ ███████║█████╗ ██║ █████╔╝ ███████╗ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
117 ██╔══██╗██╔══██║╚════██║██║██║ ██║ ██╔══██║██╔══╝ ██║ ██╔═██╗ ╚════██║ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
118 ██████╔╝██║ ██║███████║██║╚██████╗ ╚██████╗██║ ██║███████╗╚██████╗██║ ██╗███████║ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
119 ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═════╝ ╚═════╝╚═╝ ╚═╝╚══════╝ ╚═════╝╚═╝ ╚═╝╚══════╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
120 http://patorjk.com/software/taag/#p=display&f=ANSI%20Shadow&t=BASIC%20CHECKS |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
121 */ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
122 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
123 // (0x3006, 0x0080) seq. size |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
124 EXPECT_EQ(7u, structures.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
125 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
126 // (0x3006, 0x0080)[i]/(0x3006, 0x00a4) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
127 for (size_t i = 0; i < 5; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
128 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
129 EXPECT_EQ(std::string("ORGAN"), structures[i].interpretation_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
130 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
131 EXPECT_EQ(std::string("EXTERNAL"), structures[5].interpretation_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
132 EXPECT_EQ(std::string("PTV"), structures[6].interpretation_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
133 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
134 // (0x3006, 0x0020)[i]/(0x3006, 0x0026) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
135 EXPECT_EQ(std::string("LN300"), structures[0].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
136 EXPECT_EQ(std::string("Cortical Bone"), structures[1].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
137 EXPECT_EQ(std::string("Adipose"), structures[2].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
138 EXPECT_EQ(std::string("CB2-50%"), structures[3].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
139 EXPECT_EQ(std::string("Water"), structures[4].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
140 EXPECT_EQ(std::string("External"), structures[5].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
141 EXPECT_EQ(std::string("PTV"), structures[6].name_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
142 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
143 // (0x3006, 0x0039)[i]/(0x3006, 0x002a) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
144 EXPECT_EQ(0xff, structures[0].red_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
145 EXPECT_EQ(0x00, structures[0].green_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
146 EXPECT_EQ(0x00, structures[0].blue_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
147 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
148 EXPECT_EQ(0x00, structures[1].red_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
149 EXPECT_EQ(0xff, structures[1].green_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
150 EXPECT_EQ(0xff, structures[1].blue_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
151 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
152 // ... |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
153 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
154 EXPECT_EQ(0x00, structures[5].red_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
155 EXPECT_EQ(0x80, structures[5].green_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
156 EXPECT_EQ(0x00, structures[5].blue_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
157 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
158 EXPECT_EQ(0xff, structures[6].red_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
159 EXPECT_EQ(0x00, structures[6].green_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
160 EXPECT_EQ(0xff, structures[6].blue_); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
161 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
162 /* |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
163 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
164 ██████╗ ███████╗ ██████╗ ███╗ ███╗███████╗████████╗██████╗ ██╗ ██╗ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
165 ██╔════╝ ██╔════╝██╔═══██╗████╗ ████║██╔════╝╚══██╔══╝██╔══██╗╚██╗ ██╔╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
166 ██║ ███╗█████╗ ██║ ██║██╔████╔██║█████╗ ██║ ██████╔╝ ╚████╔╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
167 ██║ ██║██╔══╝ ██║ ██║██║╚██╔╝██║██╔══╝ ██║ ██╔══██╗ ╚██╔╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
168 ╚██████╔╝███████╗╚██████╔╝██║ ╚═╝ ██║███████╗ ██║ ██║ ██║ ██║ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
169 ╚═════╝ ╚══════╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
170 http://patorjk.com/software/taag/#p=display&f=ANSI%20Shadow&t=BASIC%20CHECKS |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
171 */ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
172 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
173 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
174 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
175 double groundTruthRaw[] = { 7.657838, 108.2725, 304.01, 6.826687, 107.4413, 304.01, 6.152492, 106.4785, 304.01, 5.655735, 105.4132, 304.01, 5.351513, 104.2778, 304.01, 5.249068, 103.1069, 304.01, 5.351513, 101.9359, 304.01, 5.655735, 100.8005, 304.01, 6.152492, 99.73524, 304.01, 6.826687, 98.77239, 304.01, 7.657838, 97.94124, 304.01, 8.620689, 97.26704, 304.01, 9.685987, 96.77029, 304.01, 10.82136, 96.46606, 304.01, 11.99231, 96.36362, 304.01, 13.16326, 96.46606, 304.01, 14.29864, 96.77029, 304.01, 15.36393, 97.26704, 304.01, 16.32678, 97.94124, 304.01, 17.15794, 98.77239, 304.01, 17.83213, 99.73524, 304.01, 18.32889, 100.8005, 304.01, 18.63311, 101.9359, 304.01, 18.73555, 103.1069, 304.01, 18.63311, 104.2778, 304.01, 18.32889, 105.4132, 304.01, 17.83213, 106.4785, 304.01, 17.15794, 107.4413, 304.01, 16.32678, 108.2725, 304.01, 15.36393, 108.9467, 304.01, 14.29864, 109.4434, 304.01, 13.16326, 109.7477, 304.01, 11.99231, 109.8501, 304.01, 10.82136, 109.7477, 304.01, 9.685987, 109.4434, 304.01, 8.620689, 108.9467, 304.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
176 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
177 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
178 CheckGroundTruth(structures, 0, 0, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
179 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
180 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
181 double groundTruthRaw[] = { 7.657838, 108.2725, 310.01, 6.826687, 107.4413, 310.01, 6.152492, 106.4785, 310.01, 5.655735, 105.4132, 310.01, 5.351513, 104.2778, 310.01, 5.249068, 103.1069, 310.01, 5.351513, 101.9359, 310.01, 5.655735, 100.8005, 310.01, 6.152492, 99.73524, 310.01, 6.826687, 98.77239, 310.01, 7.657838, 97.94124, 310.01, 8.620689, 97.26704, 310.01, 9.685987, 96.77029, 310.01, 10.82136, 96.46606, 310.01, 11.99231, 96.36362, 310.01, 13.16326, 96.46606, 310.01, 14.29864, 96.77029, 310.01, 15.36393, 97.26704, 310.01, 16.32678, 97.94124, 310.01, 17.15794, 98.77239, 310.01, 17.83213, 99.73524, 310.01, 18.32889, 100.8005, 310.01, 18.63311, 101.9359, 310.01, 18.73555, 103.1069, 310.01, 18.63311, 104.2778, 310.01, 18.32889, 105.4132, 310.01, 17.83213, 106.4785, 310.01, 17.15794, 107.4413, 310.01, 16.32678, 108.2725, 310.01, 15.36393, 108.9467, 310.01, 14.29864, 109.4434, 310.01, 13.16326, 109.7477, 310.01, 11.99231, 109.8501, 310.01, 10.82136, 109.7477, 310.01, 9.685987, 109.4434, 310.01, 8.620689, 108.9467, 310.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
182 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
183 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
184 CheckGroundTruth(structures, 0, 2, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
185 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
186 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
187 double groundTruthRaw[] = { -37.967, 161.9664, 304.01, -39.10237, 161.6622, 304.01, -40.16767, 161.1655, 304.01, -41.13052, 160.4913, 304.01, -41.96167, 159.6601, 304.01, -42.63587, 158.6973, 304.01, -43.13263, 157.632, 304.01, -43.43685, 156.4966, 304.01, -43.53929, 155.3257, 304.01, -43.43685, 154.1547, 304.01, -43.13263, 153.0193, 304.01, -42.63587, 151.954, 304.01, -41.96167, 150.9912, 304.01, -41.13052, 150.16, 304.01, -40.16767, 149.4858, 304.01, -39.10237, 148.9891, 304.01, -37.967, 148.6849, 304.01, -36.79605, 148.5824, 304.01, -35.6251, 148.6849, 304.01, -34.48972, 148.9891, 304.01, -33.42443, 149.4858, 304.01, -32.46157, 150.16, 304.01, -31.63042, 150.9912, 304.01, -30.95623, 151.954, 304.01, -30.45947, 153.0193, 304.01, -30.15525, 154.1547, 304.01, -30.0528, 155.3257, 304.01, -30.15525, 156.4966, 304.01, -30.45947, 157.632, 304.01, -30.95623, 158.6973, 304.01, -31.63042, 159.6601, 304.01, -32.46157, 160.4913, 304.01, -33.42443, 161.1655, 304.01, -34.48972, 161.6622, 304.01, -35.6251, 161.9664, 304.01, -36.79605, 162.0689, 304.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
188 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
189 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
190 CheckGroundTruth(structures, 1, 0, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
191 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
192 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
193 double groundTruthRaw[] = { 69.4042, 150.7324, 307.01, 69.70842, 151.8678, 307.01, 69.81087, 153.0387, 307.01, 69.70842, 154.2097, 307.01, 69.4042, 155.345, 307.01, 68.90745, 156.4103, 307.01, 68.23325, 157.3732, 307.01, 67.4021, 158.2043, 307.01, 66.43925, 158.8785, 307.01, 65.37395, 159.3753, 307.01, 64.23858, 159.6795, 307.01, 63.06762, 159.7819, 307.01, 61.89667, 159.6795, 307.01, 60.7613, 159.3753, 307.01, 59.696, 158.8785, 307.01, 58.73315, 158.2043, 307.01, 57.902, 157.3732, 307.01, 57.22781, 156.4103, 307.01, 56.73105, 155.345, 307.01, 56.42683, 154.2097, 307.01, 56.32438, 153.0387, 307.01, 56.42683, 151.8678, 307.01, 56.73105, 150.7324, 307.01, 57.22781, 149.6671, 307.01, 57.902, 148.7042, 307.01, 58.73315, 147.8731, 307.01, 59.696, 147.1989, 307.01, 60.7613, 146.7021, 307.01, 61.89667, 146.3979, 307.01, 63.06762, 146.2955, 307.01, 64.23858, 146.3979, 307.01, 65.37395, 146.7021, 307.01, 66.43925, 147.1989, 307.01, 67.4021, 147.8731, 307.01, 68.23325, 148.7042, 307.01, 68.90745, 149.6671, 307.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
194 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
195 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
196 CheckGroundTruth(structures, 2, 1, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
197 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
198 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
199 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
200 double groundTruthRaw[] = { 108.3984, 232.7406, 274.01, 106.0547, 231.7948, 274.01, 103.7109, 232.8407, 274.01, 96.67969, 232.8757, 274.01, 77.92969, 232.887, 274.01, 47.46094, 232.8902, 274.01, 38.08594, 232.7537, 274.01, 37.6668, 232.3734, 274.01, 38.08594, 231.9774, 274.01, 40.42969, 231.8475, 274.01, 41.76413, 230.0297, 274.01, 42.77344, 229.1388, 274.01, 45.11719, 228.5069, 274.01, 47.46094, 227.1533, 274.01, 49.80469, 226.3505, 274.01, 52.14844, 224.6564, 274.01, 54.49219, 223.923, 274.01, 56.83594, 222.0692, 274.01, 59.17969, 220.3438, 274.01, 61.52344, 219.3888, 274.01, 63.86719, 217.1287, 274.01, 65.83488, 215.9672, 274.01, 68.55469, 213.2383, 274.01, 70.89844, 211.2328, 274.01, 72.8125, 208.9359, 274.01, 75.58594, 206.3615, 274.01, 76.91445, 204.2484, 274.01, 78.89509, 201.9047, 274.01, 80.51276, 199.5609, 274.01, 81.51955, 197.2172, 274.01, 83.67448, 194.8734, 274.01, 84.60938, 192.5297, 274.01, 85.86986, 190.1859, 274.01, 86.57623, 187.8422, 274.01, 88.30051, 185.4984, 274.01, 88.94002, 183.1547, 274.01, 89.23261, 180.8109, 274.01, 89.64844, 180.3263, 274.01, 90.71885, 178.4672, 274.01, 90.97656, 176.1234, 274.01, 91.99219, 174.4794, 274.01, 92.56773, 173.7797, 274.01, 92.80016, 171.4359, 274.01, 93.23473, 169.0922, 274.01, 93.37606, 166.7484, 274.01, 93.60748, 157.3734, 274.01, 93.6341, 152.6859, 274.01, 93.35742, 140.9672, 274.01, 92.89317, 138.6234, 274.01, 92.7069, 136.2797, 274.01, 92.03726, 133.9359, 274.01, 90.84009, 131.5922, 274.01, 90.3769, 129.2484, 274.01, 89.09074, 126.9047, 274.01, 88.13225, 122.2172, 274.01, 86.17828, 119.8734, 274.01, 84.96094, 117.4163, 274.01, 83.99619, 115.1859, 274.01, 83.13079, 112.8422, 274.01, 82.61719, 112.2984, 274.01, 80.27344, 108.8454, 274.01, 79.64514, 108.1547, 274.01, 77.21497, 105.8109, 274.01, 76.47787, 103.4672, 274.01, 75.58594, 102.6177, 274.01, 73.24219, 100.0077, 274.01, 69.54492, 96.43594, 274.01, 67.34096, 94.09219, 274.01, 64.66306, 91.74844, 274.01, 63.86719, 90.92619, 274.01, 61.52344, 90.20454, 274.01, 59.17969, 87.78574, 274.01, 56.83594, 86.48566, 274.01, 54.49219, 84.31388, 274.01, 52.14844, 83.44438, 274.01, 49.80469, 82.75121, 274.01, 49.37617, 82.37344, 274.01, 47.46094, 81.26244, 274.01, 45.71391, 80.02969, 274.01, 45.11719, 79.45415, 274.01, 42.77344, 79.08185, 274.01, 40.42969, 78.51941, 274.01, 38.08594, 78.27534, 274.01, 37.36932, 77.68594, 274.01, 35.74219, 76.67624, 274.01, 33.39844, 76.49941, 274.01, 31.05469, 76.03495, 274.01, 28.71094, 74.83174, 274.01, 26.36719, 74.62859, 274.01, 24.02344, 74.55463, 274.01, 21.67969, 74.22861, 274.01, 19.33594, 74.05312, 274.01, 12.30469, 73.99397, 274.01, 5.273438, 74.0736, 274.01, 2.929688, 74.55463, 274.01, 0.5859375, 74.68513, 274.01, -1.757813, 74.914, 274.01, -2.319131, 75.34219, 274.01, -4.101563, 76.31516, 274.01, -8.789063, 76.74514, 274.01, -11.13281, 78.39038, 274.01, -13.47656, 78.6124, 274.01, -15.82031, 79.19784, 274.01, -18.16406, 81.11024, 274.01, -20.50781, 82.03296, 274.01, -22.85156, 83.13991, 274.01, -25.19531, 83.70732, 274.01, -27.53906, 85.85863, 274.01, -29.88281, 87.03368, 274.01, -32.22656, 88.3274, 274.01, -34.57031, 90.53674, 274.01, -36.91406, 92.5602, 274.01, -39.25781, 93.55952, 274.01, -41.60156, 95.74537, 274.01, -43.94531, 98.26609, 274.01, -46.28906, 100.3701, 274.01, -47.02621, 101.1234, 274.01, -47.86611, 103.4672, 274.01, -49.83594, 105.8109, 274.01, -51.98182, 108.1547, 274.01, -53.06448, 110.4984, 274.01, -53.32031, 110.7675, 274.01, -54.53804, 112.8422, 274.01, -55.66406, 114.273, 274.01, -56.55722, 115.1859, 274.01, -57.13953, 117.5297, 274.01, -58.29264, 119.8734, 274.01, -59.26869, 122.2172, 274.01, -60.35156, 124.0119, 274.01, -60.84229, 124.5609, 274.01, -61.54484, 126.9047, 274.01, -61.71691, 129.2484, 274.01, -63.62281, 131.5922, 274.01, -63.81256, 133.9359, 274.01, -64.12511, 136.2797, 274.01, -64.84515, 138.6234, 274.01, -65.13599, 140.9672, 274.01, -65.33604, 143.3109, 274.01, -65.87358, 145.6547, 274.01, -66.10577, 147.9984, 274.01, -66.17618, 155.0297, 274.01, -66.09933, 162.0609, 274.01, -65.40382, 164.4047, 274.01, -65.24833, 166.7484, 274.01, -64.71442, 171.4359, 274.01, -63.88171, 173.7797, 274.01, -63.69299, 176.1234, 274.01, -61.79081, 178.4672, 274.01, -61.59269, 180.8109, 274.01, -61.19405, 183.1547, 274.01, -60.35156, 185.2055, 274.01, -59.08288, 187.8422, 274.01, -58.00781, 189.3499, 274.01, -57.25858, 190.1859, 274.01, -56.64558, 192.5297, 274.01, -55.29191, 194.8734, 274.01, -54.28698, 197.2172, 274.01, -52.28595, 199.5609, 274.01, -51.47569, 201.9047, 274.01, -48.63281, 204.6417, 274.01, -47.10181, 206.5922, 274.01, -44.64154, 208.9359, 274.01, -42.38504, 211.2797, 274.01, -39.25781, 214.4025, 274.01, -37.42723, 215.9672, 274.01, -34.57031, 218.9107, 274.01, -32.22656, 219.7277, 274.01, -29.88281, 221.6934, 274.01, -27.53906, 222.852, 274.01, -25.19531, 224.5168, 274.01, -22.85156, 225.9419, 274.01, -20.50781, 226.7359, 274.01, -18.16406, 228.3332, 274.01, -15.82031, 229.065, 274.01, -13.47656, 229.267, 274.01, -12.63854, 230.0297, 274.01, -11.13281, 231.9201, 274.01, -10.65505, 232.3734, 274.01, -11.13281, 232.7794, 274.01, -15.82031, 232.792, 274.01, -18.16406, 232.8902, 274.01, -36.91406, 232.9015, 274.01, -39.25781, 232.8902, 274.01, -50.97656, 232.9236, 274.01, -60.35156, 232.9126, 274.01, -67.38281, 232.8407, 274.01, -72.07031, 232.8642, 274.01, -79.10156, 232.8555, 274.01, -83.78906, 232.8788, 274.01, -95.50781, 232.8902, 274.01, -97.85156, 233.4886, 274.01, -100.1953, 233.647, 274.01, -102.5391, 232.9858, 274.01, -104.8828, 233.6969, 274.01, -109.5703, 233.722, 274.01, -125.9766, 233.7086, 274.01, -128.3203, 233.2849, 274.01, -130.6641, 233.702, 274.01, -135.3516, 233.727, 274.01, -149.4141, 233.7135, 274.01, -156.4453, 233.727, 274.01, -163.4766, 233.7119, 274.01, -168.1641, 233.7643, 274.01, -191.6016, 233.7809, 274.01, -210.3516, 233.7716, 274.01, -224.4141, 233.7998, 274.01, -233.7891, 233.7647, 274.01, -243.1641, 233.7785, 274.01, -247.8516, 233.7378, 274.01, -254.8828, 233.8578, 274.01, -257.2266, 235.2519, 274.01, -259.5703, 236.0817, 274.01, -260.7617, 237.0609, 274.01, -261.9141, 238.2262, 274.01, -262.8989, 239.4047, 274.01, -262.9743, 241.7484, 274.01, -262.5977, 244.0922, 274.01, -260.6675, 246.4359, 274.01, -259.6161, 248.7797, 274.01, -257.2266, 251.0035, 274.01, -255.0361, 253.4672, 274.01, -252.5391, 256.0995, 274.01, -251.2277, 258.1547, 274.01, -246.7444, 262.8422, 274.01, -243.1641, 266.3515, 274.01, -239.7411, 269.8734, 274.01, -238.4766, 270.9495, 274.01, -237.2269, 272.2172, 274.01, -236.1328, 273.5215, 274.01, -235.0934, 274.5609, 274.01, -233.7891, 275.6655, 274.01, -232.5319, 276.9047, 274.01, -231.4453, 278.1693, 274.01, -227.917, 281.5922, 274.01, -224.4141, 285.1802, 274.01, -222.0703, 287.4025, 274.01, -218.6841, 290.9672, 274.01, -217.3828, 291.9709, 274.01, -215.0391, 293.1788, 274.01, -212.6953, 294.5138, 274.01, -210.3516, 295.2614, 274.01, -209.8994, 295.6547, 274.01, -208.0078, 296.7083, 274.01, -203.3203, 296.9372, 274.01, -196.2891, 296.9317, 274.01, -193.9453, 296.8988, 274.01, -172.8516, 296.8482, 274.01, -161.1328, 296.843, 274.01, -137.6953, 296.8542, 274.01, -130.6641, 296.8378, 274.01, -107.2266, 296.8379, 274.01, -93.16406, 296.8208, 274.01, -74.41406, 296.838, 274.01, -65.03906, 296.8609, 274.01, -50.97656, 296.8556, 274.01, -46.28906, 296.9051, 274.01, -41.60156, 298.5331, 274.01, -39.25781, 298.5624, 274.01, -36.91406, 297.1455, 274.01, -34.57031, 297.0498, 274.01, -32.22656, 298.5589, 274.01, -25.19531, 298.5624, 274.01, -22.85156, 297.2842, 274.01, -20.50781, 298.5624, 274.01, -1.757813, 298.5624, 274.01, 0.5859375, 297.2104, 274.01, 2.929688, 298.5624, 274.01, 5.273438, 297.6946, 274.01, 7.617188, 298.5168, 274.01, 9.960938, 298.5512, 274.01, 12.30469, 296.937, 274.01, 14.64844, 298.5478, 274.01, 16.99219, 298.5478, 274.01, 19.33594, 297.0782, 274.01, 21.67969, 296.844, 274.01, 23.54531, 297.9984, 274.01, 24.02344, 298.4023, 274.01, 24.50156, 297.9984, 274.01, 26.36719, 296.844, 274.01, 38.08594, 296.8381, 274.01, 52.14844, 296.8033, 274.01, 59.17969, 296.8033, 274.01, 73.24219, 296.7682, 274.01, 99.02344, 296.7566, 274.01, 117.7734, 296.7216, 274.01, 129.4922, 296.7152, 274.01, 131.8359, 295.9083, 274.01, 134.1797, 295.5245, 274.01, 138.8672, 295.4763, 274.01, 155.2734, 295.4763, 274.01, 176.3672, 295.3861, 274.01, 190.4297, 295.3718, 274.01, 197.4609, 295.4763, 274.01, 202.1484, 295.4454, 274.01, 204.4922, 295.3438, 274.01, 206.8359, 295.0757, 274.01, 209.1797, 294.4124, 274.01, 211.5234, 292.3133, 274.01, 213.8672, 291.0809, 274.01, 216.2109, 289.6743, 274.01, 217.3081, 288.6234, 274.01, 219.3558, 286.2797, 274.01, 221.8608, 283.9359, 274.01, 225.5859, 280.045, 274.01, 227.9297, 277.8885, 274.01, 230.2734, 275.2857, 274.01, 232.6172, 273.2225, 274.01, 233.6225, 272.2172, 274.01, 234.9609, 270.5822, 274.01, 238.2254, 267.5297, 274.01, 240.3691, 265.1859, 274.01, 244.3359, 261.3326, 274.01, 246.6797, 258.8034, 274.01, 249.0234, 256.7196, 274.01, 251.3672, 254.0746, 274.01, 254.5313, 251.1234, 274.01, 255.333, 248.7797, 274.01, 257.3723, 246.4359, 274.01, 259.7201, 244.0922, 274.01, 260.106, 241.7484, 274.01, 261.6423, 239.4047, 274.01, 261.0804, 237.0609, 274.01, 259.3552, 234.7172, 274.01, 258.3984, 233.7696, 274.01, 256.0547, 232.8757, 274.01, 253.7109, 232.792, 274.01, 251.3672, 232.8161, 274.01, 246.6797, 232.6981, 274.01, 244.3359, 232.725, 274.01, 239.6484, 232.9137, 274.01, 234.9609, 232.8525, 274.01, 225.5859, 232.8757, 274.01, 209.1797, 232.8757, 274.01, 204.4922, 232.7537, 274.01, 195.1172, 232.7794, 274.01, 171.6797, 232.792, 274.01, 164.6484, 232.7666, 274.01, 152.9297, 232.7666, 274.01, 148.2422, 232.792, 274.01, 138.8672, 232.7406, 274.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
201 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
202 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
203 EXPECT_EQ(340u * 3, groundTruth.size()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
204 CheckGroundTruth(structures, 5, 0, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
205 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
206 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
207 { |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
208 double groundTruthRaw[] = { -18.16406, 233.0632, 298.01, -27.53906, 233.1042, 298.01, -29.88281, 233.0819, 298.01, -34.57031, 233.131, 298.01, -43.94531, 233.1221, 298.01, -50.97656, 233.1736, 298.01, -62.69531, 233.1397, 298.01, -65.03906, 232.8376, 298.01, -69.72656, 232.9839, 298.01, -79.10156, 233.0245, 298.01, -90.82031, 233.0382, 298.01, -93.16406, 233.0859, 298.01, -109.5703, 233.1132, 298.01, -111.9141, 233.1791, 298.01, -114.2578, 233.7139, 298.01, -118.9453, 233.9793, 298.01, -128.3203, 234.0284, 298.01, -130.6641, 233.9793, 298.01, -135.3516, 234.0591, 298.01, -137.6953, 234.0284, 298.01, -142.3828, 234.0855, 298.01, -144.7266, 234.0284, 298.01, -151.7578, 234.002, 298.01, -158.7891, 234.0263, 298.01, -163.4766, 233.9784, 298.01, -165.8203, 234.0072, 298.01, -168.1641, 234.1756, 298.01, -170.5078, 234.2214, 298.01, -179.8828, 234.1934, 298.01, -186.9141, 234.2721, 298.01, -189.2578, 234.2289, 298.01, -193.9453, 234.2431, 298.01, -198.6328, 234.1692, 298.01, -200.9766, 234.2326, 298.01, -205.6641, 234.1271, 298.01, -212.6953, 234.2224, 298.01, -215.0391, 234.1992, 298.01, -222.0703, 234.3115, 298.01, -224.4141, 234.2224, 298.01, -226.7578, 234.2502, 298.01, -233.7891, 234.0906, 298.01, -238.4766, 234.0329, 298.01, -243.1641, 234.0283, 298.01, -247.8516, 233.7949, 298.01, -250.1953, 233.8681, 298.01, -252.5391, 234.7626, 298.01, -254.3469, 237.0609, 298.01, -255.6034, 239.4047, 298.01, -254.5181, 241.7484, 298.01, -254.2274, 244.0922, 298.01, -254.181, 248.7797, 298.01, -253.9355, 251.1234, 298.01, -253.5926, 253.4672, 298.01, -252.7483, 255.8109, 298.01, -250.8092, 258.1547, 298.01, -248.713, 260.4984, 298.01, -246.263, 262.8422, 298.01, -244.1406, 265.1859, 298.01, -241.6671, 267.5297, 298.01, -239.4754, 269.8734, 298.01, -237.0156, 272.2172, 298.01, -233.7891, 275.382, 298.01, -231.4453, 277.8249, 298.01, -229.1016, 279.9981, 298.01, -226.7578, 282.5281, 298.01, -224.4141, 284.6784, 298.01, -222.0703, 287.2355, 298.01, -220.5414, 288.6234, 298.01, -218.2745, 290.9672, 298.01, -217.3828, 291.6508, 298.01, -212.6953, 294.5949, 298.01, -210.3516, 295.3142, 298.01, -208.0078, 296.4674, 298.01, -205.6641, 296.8852, 298.01, -203.3203, 297.1563, 298.01, -196.2891, 297.1488, 298.01, -193.9453, 297.0597, 298.01, -182.2266, 296.9529, 298.01, -168.1641, 296.8576, 298.01, -154.1016, 296.9249, 298.01, -149.4141, 296.8921, 298.01, -128.3203, 296.9228, 298.01, -121.2891, 296.8623, 298.01, -111.9141, 296.8549, 298.01, -107.2266, 296.8266, 298.01, -102.5391, 296.8731, 298.01, -95.50781, 296.8453, 298.01, -88.47656, 296.9218, 298.01, -83.78906, 296.9016, 298.01, -69.72656, 296.979, 298.01, -67.38281, 296.9514, 298.01, -65.03906, 297.2199, 298.01, -62.69531, 296.9622, 298.01, -55.66406, 296.9926, 298.01, -50.97656, 296.9467, 298.01, -48.63281, 297.3652, 298.01, -46.28906, 297.0439, 298.01, -43.94531, 297.2875, 298.01, -39.25781, 297.0121, 298.01, -34.57031, 297.1564, 298.01, -32.22656, 297.3612, 298.01, -29.88281, 297.4229, 298.01, -27.53906, 297.1687, 298.01, -25.19531, 297.4334, 298.01, -18.16406, 297.3612, 298.01, -15.82031, 297.4441, 298.01, -13.47656, 297.4125, 298.01, -11.13281, 297.2468, 298.01, -8.789063, 297.4125, 298.01, -6.445313, 297.373, 298.01, -4.101563, 297.4195, 298.01, -1.757813, 297.077, 298.01, 0.5859375, 297.4229, 298.01, 2.929688, 297.4125, 298.01, 5.273438, 296.9489, 298.01, 7.617188, 297.3168, 298.01, 9.960938, 296.9377, 298.01, 12.30469, 296.8998, 298.01, 14.64844, 297.1975, 298.01, 16.99219, 296.8579, 298.01, 28.71094, 296.878, 298.01, 40.42969, 296.8163, 298.01, 42.77344, 296.8369, 298.01, 49.80469, 296.734, 298.01, 59.17969, 296.6906, 298.01, 61.52344, 296.6365, 298.01, 68.55469, 296.6278, 298.01, 73.24219, 296.5777, 298.01, 75.58594, 296.6191, 298.01, 84.96094, 296.5284, 298.01, 96.67969, 296.5538, 298.01, 103.7109, 296.479, 298.01, 115.4297, 296.4259, 298.01, 122.4609, 296.3434, 298.01, 129.4922, 296.3495, 298.01, 131.8359, 295.9141, 298.01, 136.5234, 296.2256, 298.01, 138.8672, 295.833, 298.01, 143.5547, 295.9857, 298.01, 145.8984, 295.8791, 298.01, 152.9297, 295.833, 298.01, 164.6484, 295.6819, 298.01, 171.6797, 295.6819, 298.01, 181.0547, 295.5401, 298.01, 185.7422, 295.5742, 298.01, 192.7734, 295.557, 298.01, 197.4609, 295.8012, 298.01, 202.1484, 295.6819, 298.01, 204.4922, 295.3698, 298.01, 206.8359, 294.803, 298.01, 209.1797, 294.3656, 298.01, 211.5234, 292.4764, 298.01, 213.8672, 291.1765, 298.01, 216.2109, 289.5873, 298.01, 217.229, 288.6234, 298.01, 218.5547, 287.0752, 298.01, 221.7097, 283.9359, 298.01, 225.5859, 279.8775, 298.01, 227.9297, 277.5633, 298.01, 230.2734, 275.0808, 298.01, 233.1989, 272.2172, 298.01, 234.9609, 270.2887, 298.01, 237.7384, 267.5297, 298.01, 241.9922, 263.0843, 298.01, 244.3359, 260.7643, 298.01, 246.788, 258.1547, 298.01, 249.0234, 255.451, 298.01, 250.3651, 253.4672, 298.01, 251.5297, 251.1234, 298.01, 252.1947, 248.7797, 298.01, 252.4915, 246.4359, 298.01, 252.5755, 241.7484, 298.01, 252.8592, 239.4047, 298.01, 252.9236, 237.0609, 298.01, 252.2924, 234.7172, 298.01, 251.3672, 233.4697, 298.01, 249.0234, 232.882, 298.01, 244.3359, 232.9048, 298.01, 241.9922, 233.0145, 298.01, 232.6172, 232.9048, 298.01, 227.9297, 233.0007, 298.01, 216.2109, 233.0632, 298.01, 211.5234, 233.0537, 298.01, 206.8359, 232.9699, 298.01, 204.4922, 232.7322, 298.01, 199.8047, 232.7186, 298.01, 190.4297, 232.7719, 298.01, 183.3984, 232.7719, 298.01, 181.0547, 232.7322, 298.01, 174.0234, 232.7048, 298.01, 171.6797, 232.7322, 298.01, 166.9922, 232.6908, 298.01, 157.6172, 232.7975, 298.01, 155.2734, 232.7588, 298.01, 148.2422, 232.7875, 298.01, 143.5547, 232.7614, 298.01, 138.8672, 232.6477, 298.01, 124.8047, 232.6179, 298.01, 122.4609, 232.6477, 298.01, 113.0859, 232.6027, 298.01, 110.7422, 232.4552, 298.01, 108.3984, 232.2192, 298.01, 106.0547, 231.6764, 298.01, 103.7109, 231.8559, 298.01, 102.8237, 232.3734, 298.01, 101.3672, 232.9839, 298.01, 99.02344, 233.0951, 298.01, 87.30469, 233.0819, 298.01, 84.96094, 233.1091, 298.01, 80.27344, 233.0726, 298.01, 77.92969, 233.1132, 298.01, 70.89844, 233.1397, 298.01, 68.55469, 233.1132, 298.01, 52.14844, 233.131, 298.01, 45.11719, 233.0859, 298.01, 44.16726, 232.3734, 298.01, 42.77344, 231.0206, 298.01, 42.04498, 230.0297, 298.01, 42.77344, 229.2462, 298.01, 45.11719, 228.5664, 298.01, 47.46094, 227.0695, 298.01, 49.80469, 226.0552, 298.01, 52.14844, 224.5723, 298.01, 54.49219, 223.6857, 298.01, 56.83594, 221.8519, 298.01, 59.17969, 220.2086, 298.01, 61.52344, 218.8854, 298.01, 64.94469, 215.9672, 298.01, 66.21094, 215.0191, 298.01, 67.72036, 213.6234, 298.01, 68.55469, 212.6986, 298.01, 70.89844, 210.5055, 298.01, 74.53191, 206.5922, 298.01, 76.54903, 204.2484, 298.01, 78.26105, 201.9047, 298.01, 80.27344, 198.9262, 298.01, 82.61719, 195.2822, 298.01, 82.98087, 194.8734, 298.01, 84.96094, 190.9255, 298.01, 85.43701, 190.1859, 298.01, 86.33423, 187.8422, 298.01, 87.78722, 185.4984, 298.01, 88.60233, 183.1547, 298.01, 89.10253, 180.8109, 298.01, 90.17504, 178.4672, 298.01, 90.88959, 176.1234, 298.01, 91.43783, 173.7797, 298.01, 92.39601, 171.4359, 298.01, 92.95762, 169.0922, 298.01, 93.55695, 159.7172, 298.01, 93.65527, 157.3734, 298.01, 93.67542, 152.6859, 298.01, 93.61213, 150.3422, 298.01, 93.22542, 143.3109, 298.01, 93.06345, 140.9672, 298.01, 92.77563, 138.6234, 298.01, 91.21714, 133.9359, 298.01, 90.67235, 131.5922, 298.01, 89.88776, 129.2484, 298.01, 88.8737, 126.9047, 298.01, 88.44087, 124.5609, 298.01, 86.09712, 119.8734, 298.01, 85.05786, 117.5297, 298.01, 83.87151, 115.1859, 298.01, 82.22388, 112.8422, 298.01, 81.09117, 110.4984, 298.01, 77.92969, 106.4052, 298.01, 77.3894, 105.8109, 298.01, 75.94332, 103.4672, 298.01, 71.71799, 98.77969, 298.01, 68.55469, 95.65721, 298.01, 63.86719, 91.54878, 298.01, 61.52344, 90.1121, 298.01, 59.17969, 88.15762, 298.01, 56.83594, 86.51503, 298.01, 54.49219, 85.42721, 298.01, 52.14844, 83.64907, 298.01, 49.80469, 82.89023, 298.01, 47.46094, 81.50237, 298.01, 45.11719, 80.62591, 298.01, 42.77344, 79.18153, 298.01, 40.42969, 78.7203, 298.01, 38.08594, 78.1349, 298.01, 35.74219, 77.11755, 298.01, 33.39844, 76.51949, 298.01, 31.05469, 76.07934, 298.01, 26.36719, 74.67744, 298.01, 24.02344, 74.42056, 298.01, 14.64844, 74.07317, 298.01, 9.960938, 74.11538, 298.01, 2.929688, 74.40105, 298.01, 0.5859375, 74.67952, 298.01, -1.757813, 75.31406, 298.01, -4.101563, 76.07065, 298.01, -6.445313, 76.49051, 298.01, -8.789063, 77.17276, 298.01, -11.13281, 78.20097, 298.01, -15.82031, 79.31967, 298.01, -18.16406, 80.76948, 298.01, -20.50781, 81.64266, 298.01, -22.85156, 83.0305, 298.01, -25.19531, 83.7937, 298.01, -27.53906, 85.63515, 298.01, -29.88281, 86.7363, 298.01, -32.22656, 88.36089, 298.01, -34.57031, 90.3302, 298.01, -36.56719, 91.74844, 298.01, -41.60156, 95.93605, 298.01, -46.58845, 101.1234, 298.01, -50.17995, 105.8109, 298.01, -52.10386, 108.1547, 298.01, -53.63992, 110.4984, 298.01, -54.95532, 112.8422, 298.01, -56.64794, 115.1859, 298.01, -57.4403, 117.5297, 298.01, -58.91927, 119.8734, 298.01, -59.78655, 122.2172, 298.01, -61.11754, 124.5609, 298.01, -61.58921, 126.9047, 298.01, -62.38012, 129.2484, 298.01, -63.49118, 131.5922, 298.01, -64.02599, 133.9359, 298.01, -64.3932, 136.2797, 298.01, -65.11897, 138.6234, 298.01, -65.64544, 140.9672, 298.01, -66.23938, 147.9984, 298.01, -66.46289, 152.6859, 298.01, -66.48911, 155.0297, 298.01, -66.34437, 159.7172, 298.01, -65.99894, 164.4047, 298.01, -65.49149, 169.0922, 298.01, -64.6875, 171.4359, 298.01, -63.7739, 176.1234, 298.01, -62.9398, 178.4672, 298.01, -61.86011, 180.8109, 298.01, -61.33423, 183.1547, 298.01, -60.43332, 185.4984, 298.01, -58.00781, 190.0632, 298.01, -56.85406, 192.5297, 298.01, -55.66406, 194.7283, 298.01, -54.11692, 197.2172, 298.01, -50.97656, 201.8369, 298.01, -47.36435, 206.5922, 298.01, -45.04395, 208.9359, 298.01, -42.83026, 211.2797, 298.01, -39.25781, 214.7435, 298.01, -34.57031, 218.4974, 298.01, -32.22656, 219.9595, 298.01, -28.02053, 222.9984, 298.01, -27.53906, 223.4238, 298.01, -25.19531, 224.4187, 298.01, -22.85156, 225.8252, 298.01, -20.50781, 226.9067, 298.01, -18.16406, 228.4286, 298.01, -15.82031, 229.1235, 298.01, -14.9447, 230.0297, 298.01, -15.82031, 231.3969, 298.01, -16.94484, 232.3734, 298.01 }; |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
209 size_t n = sizeof(groundTruthRaw) / sizeof(groundTruthRaw[0]); |
1012
050f01d7951b
Ugly fix for VS2008 (pre-C++11 vector initialization)
Benjamin Golinvaux <bgo@osimis.io>
parents:
1010
diff
changeset
|
210 std::vector<double> groundTruth(groundTruthRaw, groundTruthRaw+n); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
211 EXPECT_EQ(358u * 3, groundTruth.size()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
212 CheckGroundTruth(structures, 5, 8, groundTruth); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
213 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
214 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
215 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
216 #endif |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
217 // BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
218 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
219 #if 0 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
220 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
221 TEST(StructureSet2, ReadFromJsonAndCompute1) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
222 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
223 DicomStructureSet2 structureSet; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
224 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
225 OrthancPlugins::FullOrthancDataset dicom(GetTestJson()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
226 structureSet.Clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
227 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
228 structureSet.FillStructuresFromDataset(dicom); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
229 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
230 structureSet.ComputeDependentProperties(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
231 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
232 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
233 TEST(StructureSet2, ReadFromJsonAndCompute2) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
234 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
235 DicomStructureSet2 structureSet; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
236 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
237 OrthancPlugins::FullOrthancDataset dicom(GetTestJson()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
238 structureSet.Clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
239 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
240 structureSet.SetContents(dicom); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
241 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
242 #endif |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
243 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
244 #ifdef BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
245 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
246 static bool CutStructureWithPlane( |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
247 std::vector< std::pair<ScenePoint2D, ScenePoint2D> >& segments, |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
248 const DicomStructure2& structure, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
249 const double originX, const double originY, const double originZ, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
250 const double axisX_X, const double axisX_Y, const double axisX_Z, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
251 const double axisY_X, const double axisY_Y, const double axisY_Z |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
252 ) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
253 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
254 // create an AXIAL cutting plane, too far away from the volume |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
255 // (> sliceThickness/2) |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
256 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
257 LinearAlgebra::AssignVector(origin, originX, originY, originZ); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
258 LinearAlgebra::AssignVector(axisX, axisX_X, axisX_Y, axisX_Z); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
259 LinearAlgebra::AssignVector(axisY, axisY_X, axisY_Y, axisY_Z); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
260 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
261 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
262 // compute intersection |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
263 bool ok = structure.Project(segments, cuttingPlane); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
264 return ok; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
265 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
266 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
267 #endif |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
268 // BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
269 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
270 static double pointsCoord1[] = { 2, 2, 3, 3, 6, 8, 8, 7, 8, 8, 6 }; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
271 static double pointsCoord2[] = { 2, 6, 8, 10, 12, 10, 8, 6, 4, 2, 4 }; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
272 static const size_t pointsCoord1Count = STONE_ARRAY_SIZE(pointsCoord1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
273 static const size_t pointsCoord2Count = STONE_ARRAY_SIZE(pointsCoord2); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
274 const size_t POLYGON_POINT_COUNT = pointsCoord1Count; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
275 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
276 #ifdef BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
277 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
278 static void CreateBasicStructure(DicomStructure2& structure) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
279 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
280 // see https://www.dropbox.com/s/1o1vg53hsbvx4cc/test-rtstruct-polygons.jpg?dl=0 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
281 EXPECT_EQ(pointsCoord1Count, pointsCoord2Count); |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
282 EXPECT_EQ(11u, pointsCoord2Count); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
283 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
284 for (size_t slice = 0; slice < 3; ++slice) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
285 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
286 DicomStructurePolygon2 polygon("Oblomptu", "CLOSED_PLANAR"); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
287 for (size_t ip = 0; ip < pointsCoord1Count; ++ip) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
288 { |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
289 Vector pt; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
290 double pt0 = pointsCoord1[ip]; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
291 double pt1 = pointsCoord2[ip]; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
292 double pt2 = 4 * (static_cast<double>(slice) - 1); // -4, 0, 4 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
293 LinearAlgebra::AssignVector(pt, pt0, pt1, pt2); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
294 polygon.AddPoint(pt); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
295 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
296 structure.AddPolygon(polygon); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
297 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
298 structure.ComputeDependentProperties(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
299 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
300 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
301 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
302 TEST(StructureSet2, CutAxialOutsideTop) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
303 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
304 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
305 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
306 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
307 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
308 // create an AXIAL cutting plane, too far away from the volume |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
309 // (> sliceThickness/2) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
310 bool ok = CutStructureWithPlane(segments, structure, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
311 0, 0, 7, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
312 1, 0, 0, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
313 0, 1, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
314 EXPECT_FALSE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
315 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
316 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
317 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
318 TEST(StructureSet2, CutAxialOutsideBottom) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
319 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
320 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
321 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
322 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
323 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
324 // create an AXIAL cutting plane, too far away from the volume |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
325 // (> sliceThickness/2) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
326 bool ok = CutStructureWithPlane(segments, structure, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
327 0, 0, -6.66, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
328 1, 0, 0, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
329 0, 1, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
330 EXPECT_FALSE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
331 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
332 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
333 TEST(StructureSet2, CutAxialInsideClose) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
334 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
335 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
336 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
337 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
338 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
339 // create an AXIAL cutting plane in the volume |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
340 bool ok = CutStructureWithPlane(segments, structure, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
341 0, 0, 1.1, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
342 1, 0, 0, |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
343 0, 1, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
344 EXPECT_TRUE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
345 EXPECT_EQ(POLYGON_POINT_COUNT, segments.size()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
346 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
347 for (size_t i = 0; i < segments.size(); ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
348 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
349 EXPECT_LT(i, POLYGON_POINT_COUNT); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
350 EXPECT_LT(i, POLYGON_POINT_COUNT); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
351 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
352 const ScenePoint2D& pt = segments[i].first; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
353 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
354 // ...should be at the same location as the 3D coords since the plane |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
355 // is rooted at 0,0,0 with normal 0,0,1 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
356 EXPECT_NEAR(pt.GetX(), pointsCoord1[i], DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
357 EXPECT_NEAR(pt.GetY(), pointsCoord2[i], DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
358 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
359 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
360 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
361 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
362 TEST(StructureSet2, CutAxialInsideFar) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
363 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
364 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
365 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
366 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
367 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
368 // create an AXIAL cutting plane |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
369 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
370 LinearAlgebra::AssignVector(origin, 0, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
371 LinearAlgebra::AssignVector(axisX, 1, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
372 LinearAlgebra::AssignVector(axisY, 0, 1, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
373 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
374 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
375 // compute intersection |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
376 bool ok = structure.Project(segments, cuttingPlane); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
377 EXPECT_TRUE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
378 |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
379 EXPECT_EQ(11u, segments.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
380 for (size_t i = 0; i < segments.size(); ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
381 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
382 EXPECT_LT(i, pointsCoord1Count); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
383 EXPECT_LT(i, pointsCoord2Count); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
384 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
385 // the 2D points of the projected polygon |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
386 const ScenePoint2D& pt = segments[i].first; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
387 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
388 // ...should be at the same location as the 3D coords since the plane |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
389 // is rooted at 0,0,0 with normal 0,0,1 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
390 EXPECT_NEAR(pt.GetX(), pointsCoord1[i], DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
391 EXPECT_NEAR(pt.GetY(), pointsCoord2[i], DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
392 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
393 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
394 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
395 TEST(StructureSet2, CutCoronalOutsideClose) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
396 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
397 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
398 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
399 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
400 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
401 // create an X,Z cutting plane, outside of the volume |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
402 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
403 LinearAlgebra::AssignVector(origin, 0, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
404 LinearAlgebra::AssignVector(axisX, 1, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
405 LinearAlgebra::AssignVector(axisY, 0, 0, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
406 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
407 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
408 // compute intersection |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
409 bool ok = structure.Project(segments, cuttingPlane); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
410 EXPECT_FALSE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
411 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
412 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
413 TEST(StructureSet2, CutCoronalInsideClose1DTest) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
414 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
415 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
416 CreateBasicStructure(structure); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
417 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
418 // create an X,Z cutting plane, outside of the volume |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
419 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
420 LinearAlgebra::AssignVector(origin, 0, 3, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
421 LinearAlgebra::AssignVector(axisX, 1, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
422 LinearAlgebra::AssignVector(axisY, 0, 0, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
423 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
424 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
425 ASSERT_EQ(3u, structure.GetPolygons().size()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
426 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
427 for (int i = 0; i < 3; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
428 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
429 double polygonZ = static_cast<double>(i - 1) * 4.0; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
430 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
431 const DicomStructurePolygon2& topSlab = structure.GetPolygons()[i]; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
432 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
433 // let's compute the intersection between the polygon and the plane |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
434 // intersections are in plane coords |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
435 std::vector<ScenePoint2D> intersects; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
436 topSlab.ProjectOnConstantPlane(intersects, cuttingPlane); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
437 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
438 ASSERT_EQ(4u, intersects.size()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
439 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
440 EXPECT_NEAR(2, intersects[0].GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
441 EXPECT_NEAR(4, intersects[1].GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
442 EXPECT_NEAR(7, intersects[2].GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
443 EXPECT_NEAR(8, intersects[3].GetX(), DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
444 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
445 for (size_t i = 0; i < 4u; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
446 { |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
447 EXPECT_NEAR(polygonZ, intersects[i].GetY(), DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
448 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
449 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
450 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
451 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
452 TEST(StructureSet2, CutCoronalInsideClose) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
453 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
454 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
455 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
456 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
457 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
458 // create an X,Z cutting plane, outside of the volume |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
459 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
460 LinearAlgebra::AssignVector(origin, 0, 3, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
461 LinearAlgebra::AssignVector(axisX, 1, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
462 LinearAlgebra::AssignVector(axisY, 0, 0, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
463 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
464 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
465 // compute intersection |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
466 ASSERT_TRUE(structure.Project(segments, cuttingPlane)); |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
467 EXPECT_EQ(24u, segments.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
468 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
469 size_t numberOfVeryShortSegments = 0; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
470 for (size_t iSegment = 0; iSegment < segments.size(); ++iSegment) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
471 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
472 // count the NON vertical very short segments |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
473 if (LinearAlgebra::IsNear(segments[iSegment].first.GetX(), segments[iSegment].second.GetX())) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
474 { |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
475 if (LinearAlgebra::IsNear(segments[iSegment].first.GetY(), segments[iSegment].second.GetY())) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
476 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
477 numberOfVeryShortSegments++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
478 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
479 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
480 } |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
481 EXPECT_EQ(8u, numberOfVeryShortSegments); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
482 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
483 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
484 #endif |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
485 // BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
486 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
487 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
488 TEST(DisjointDataSet, BasicTest) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
489 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
490 const size_t ITEM_COUNT = 10; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
491 DisjointDataSet ds(ITEM_COUNT); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
492 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
493 for (size_t i = 0; i < ITEM_COUNT; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
494 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
495 EXPECT_EQ(i, ds.Find(i)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
496 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
497 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
498 ds.Union(0, 4); |
1168
f2951ac074bd
allow compiling unit tests with sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1123
diff
changeset
|
499 EXPECT_EQ(0u, ds.Find(0)); |
f2951ac074bd
allow compiling unit tests with sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1123
diff
changeset
|
500 EXPECT_EQ(0u, ds.Find(4)); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
501 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
502 ds.Union(4, 6); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
503 ds.Union(8, 9); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
504 ds.Union(0, 8); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
505 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
506 for (size_t i = 0; i < ITEM_COUNT; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
507 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
508 size_t parent = ds.Find(i); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
509 EXPECT_TRUE(0 == parent || 1 == parent || 2 == parent || 3 == parent || 5 == parent || 7 == parent); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
510 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
511 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
512 ds.Union(1, 2); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
513 ds.Union(1, 7); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
514 for (size_t i = 0; i < ITEM_COUNT; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
515 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
516 size_t parent = ds.Find(i); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
517 EXPECT_TRUE(0 == parent || 1 == parent || 3 == parent || 5 == parent); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
518 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
519 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
520 ds.Union(3, 5); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
521 for (size_t i = 0; i < ITEM_COUNT; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
522 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
523 size_t parent = ds.Find(i); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
524 EXPECT_TRUE(0 == parent || 1 == parent || 3 == parent); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
525 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
526 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
527 EXPECT_EQ(ds.Find(0), ds.Find(0)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
528 EXPECT_EQ(ds.Find(0), ds.Find(4)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
529 EXPECT_EQ(ds.Find(0), ds.Find(6)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
530 EXPECT_EQ(ds.Find(0), ds.Find(8)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
531 EXPECT_EQ(ds.Find(0), ds.Find(8)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
532 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
533 EXPECT_EQ(ds.Find(1), ds.Find(7)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
534 EXPECT_EQ(ds.Find(2), ds.Find(1)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
535 EXPECT_EQ(ds.Find(7), ds.Find(2)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
536 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
537 EXPECT_EQ(ds.Find(3), ds.Find(5)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
538 EXPECT_EQ(ds.Find(5), ds.Find(3)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
539 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
540 ds.Union(0, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
541 ds.Union(3, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
542 for (size_t i = 0; i < ITEM_COUNT; ++i) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
543 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
544 EXPECT_EQ(ds.Find(0), ds.Find(i)); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
545 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
546 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
547 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
548 #ifdef BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
549 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
550 TEST(StructureSet2, CutSagittalInsideClose) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
551 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
552 DicomStructure2 structure; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
553 CreateBasicStructure(structure); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
554 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
555 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
556 // create an X,Z cutting plane, inside of the volume |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
557 Vector origin, axisX, axisY; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
558 LinearAlgebra::AssignVector(origin, 0, 3, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
559 LinearAlgebra::AssignVector(axisX, 1, 0, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
560 LinearAlgebra::AssignVector(axisY, 0, 0, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
561 CoordinateSystem3D cuttingPlane(origin, axisX, axisY); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
562 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
563 // compute intersection |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
564 bool ok = structure.Project(segments, cuttingPlane); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
565 EXPECT_TRUE(ok); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
566 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
567 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
568 #endif |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
569 // BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
570 |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
571 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
572 static size_t ConvertListOfSlabsToSegments_Add(RtStructRectanglesInSlab& rectangles, int row, double xmin, double xmax) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
573 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
574 double ymin = static_cast<double>(row) * 5.0; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
575 double ymax = static_cast<double>(row + 1) * 5.0; |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
576 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
577 RtStructRectangleInSlab rectangle; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
578 rectangle.xmin = xmin; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
579 rectangle.xmax = xmax; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
580 rectangle.ymin = ymin; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
581 rectangle.ymax = ymax; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
582 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
583 rectangles.push_back(rectangle); |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
584 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
585 return 1u; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
586 } |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
587 |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
588 static size_t FillTestRectangleList(std::vector< RtStructRectanglesInSlab >& rectanglesForEachSlab) |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
589 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
590 // ConvertListOfSlabsToSegments |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
591 size_t rectCount = 0; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
592 |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
593 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
594 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 0, 5, 31); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
595 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 0, 36, 50); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
596 |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
597 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
598 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 1, 20, 45); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
599 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 1, 52, 70); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
600 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
601 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
602 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 2, 0, 32); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
603 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 2, 35, 44); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
604 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 2, 60, 75); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
605 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
606 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
607 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 3, 10, 41); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
608 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 3, 46, 80); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
609 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
610 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
611 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 4, 34, 42); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
612 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 4, 90, 96); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
613 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
614 rectanglesForEachSlab.push_back(RtStructRectanglesInSlab()); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
615 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 5, 1, 33); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
616 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 5, 40, 43); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
617 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 5, 51, 61); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
618 rectCount += ConvertListOfSlabsToSegments_Add(rectanglesForEachSlab.back(), 5, 76, 95); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
619 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
620 return rectCount; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
621 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
622 |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
623 /* |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
624 void AddSlabBoundaries( |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
625 std::vector<std::pair<double, RectangleBoundaryKind> >& boundaries, |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
626 const std::vector<RtStructRectanglesInSlab>& slabCuts, size_t iSlab) |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
627 */ |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
628 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
629 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
630 /* |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
631 void ProcessBoundaryList( |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
632 std::vector< std::pair<ScenePoint2D, ScenePoint2D> >& segments, |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
633 const std::vector<std::pair<double, RectangleBoundaryKind> >& boundaries, |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
634 double y) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
635 */ |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
636 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
637 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
638 TEST(StructureSet2, ProcessBoundaryList_Empty) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
639 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
640 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
641 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
642 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
643 boundaries.clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
644 EXPECT_NO_THROW(AddSlabBoundaries(boundaries, slabCuts, 0)); |
1168
f2951ac074bd
allow compiling unit tests with sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1123
diff
changeset
|
645 ASSERT_EQ(0u, boundaries.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
646 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
647 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
648 TEST(StructureSet2, ProcessBoundaryListTopRow) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
649 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
650 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
651 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
652 FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
653 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
654 boundaries.clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
655 AddSlabBoundaries(boundaries, slabCuts, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
656 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
657 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
658 size_t i = 0; |
1168
f2951ac074bd
allow compiling unit tests with sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1123
diff
changeset
|
659 ASSERT_EQ(4u, boundaries.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
660 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
661 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
662 ASSERT_NEAR(5, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
663 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
664 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
665 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
666 ASSERT_NEAR(31, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
667 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
668 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
669 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
670 ASSERT_NEAR(36, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
671 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
672 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
673 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
674 ASSERT_NEAR(50, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
675 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
676 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
677 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
678 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
679 TEST(StructureSet2, ProcessBoundaryListRows_0_and_1) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
680 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
681 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
682 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
683 FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
684 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
685 boundaries.clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
686 AddSlabBoundaries(boundaries, slabCuts, 0); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
687 AddSlabBoundaries(boundaries, slabCuts, 1); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
688 |
1168
f2951ac074bd
allow compiling unit tests with sdl
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1123
diff
changeset
|
689 ASSERT_EQ(8u, boundaries.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
690 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
691 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
692 size_t i = 0; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
693 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
694 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
695 ASSERT_NEAR(5, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
696 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
697 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
698 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
699 ASSERT_NEAR(20, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
700 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
701 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
702 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
703 ASSERT_NEAR(31, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
704 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
705 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
706 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
707 ASSERT_NEAR(36, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
708 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
709 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
710 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
711 ASSERT_NEAR(45, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
712 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
713 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
714 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
715 ASSERT_NEAR(50, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
716 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
717 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
718 ASSERT_EQ(RectangleBoundaryKind_Start, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
719 ASSERT_NEAR(52, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
720 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
721 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
722 ASSERT_EQ(RectangleBoundaryKind_End, boundaries[i].second); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
723 ASSERT_NEAR(70, boundaries[i].first, DELTA_MAX); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
724 i++; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
725 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
726 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
727 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
728 TEST(StructureSet2, ConvertListOfSlabsToSegments_EmptyBoundaries) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
729 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
730 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
731 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
732 FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
733 boundaries.clear(); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
734 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
735 ASSERT_NO_THROW(ProcessBoundaryList(segments, boundaries, 42.0)); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
736 ASSERT_EQ(0u, segments.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
737 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
738 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
739 TEST(StructureSet2, ConvertListOfSlabsToSegments_TopRow_Horizontal) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
740 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
741 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
742 FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
743 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
744 // top row |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
745 { |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
746 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
747 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
748 AddSlabBoundaries(boundaries, slabCuts, 0); |
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
749 ProcessBoundaryList(segments, boundaries, slabCuts[0][0].ymin); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
750 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
751 ASSERT_EQ(2u, segments.size()); |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
752 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
753 ASSERT_NEAR( 5.0, segments[0].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
754 ASSERT_NEAR(31.0, segments[0].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
755 ASSERT_NEAR( 0.0, segments[0].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
756 ASSERT_NEAR( 0.0, segments[0].second.GetY(), DELTA_MAX); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
757 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
758 ASSERT_NEAR(36.0, segments[1].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
759 ASSERT_NEAR(50.0, segments[1].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
760 ASSERT_NEAR( 0.0, segments[1].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
761 ASSERT_NEAR( 0.0, segments[1].second.GetY(), DELTA_MAX); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
762 } |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
763 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
764 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
765 TEST(StructureSet2, ConvertListOfSlabsToSegments_All_Horizontal) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
766 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
767 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
768 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
769 FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
770 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
771 // top row |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
772 { |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
773 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
774 AddSlabBoundaries(boundaries, slabCuts, 0); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
775 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
776 ProcessBoundaryList(segments, boundaries, slabCuts[0][0].ymin); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
777 } |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
778 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
779 // mids |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
780 { |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
781 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
782 AddSlabBoundaries(boundaries, slabCuts, 0); |
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
783 AddSlabBoundaries(boundaries, slabCuts, 1); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
784 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
785 ProcessBoundaryList(segments, boundaries, slabCuts[0][0].ymax); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
786 |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
787 ASSERT_EQ(4u, segments.size()); |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
788 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
789 ASSERT_NEAR(05.0, segments[0].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
790 ASSERT_NEAR(20.0, segments[0].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
791 ASSERT_NEAR(05.0, segments[0].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
792 ASSERT_NEAR(05.0, segments[0].second.GetY(), DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
793 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
794 ASSERT_NEAR(31.0, segments[1].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
795 ASSERT_NEAR(36.0, segments[1].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
796 ASSERT_NEAR(05.0, segments[1].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
797 ASSERT_NEAR(05.0, segments[1].second.GetY(), DELTA_MAX); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
798 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
799 ASSERT_NEAR(45.0, segments[2].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
800 ASSERT_NEAR(50.0, segments[2].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
801 ASSERT_NEAR(05.0, segments[2].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
802 ASSERT_NEAR(05.0, segments[2].second.GetY(), DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
803 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
804 ASSERT_NEAR(52.0, segments[3].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
805 ASSERT_NEAR(70.0, segments[3].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
806 ASSERT_NEAR(05.0, segments[3].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
807 ASSERT_NEAR(05.0, segments[3].second.GetY(), DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
808 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
809 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
810 // bottom row |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
811 { |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
812 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
813 AddSlabBoundaries(boundaries, slabCuts, 1); |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
814 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
815 ProcessBoundaryList(segments, boundaries, slabCuts[1][0].ymax); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
816 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
817 ASSERT_EQ(2u, segments.size()); |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
818 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
819 ASSERT_NEAR(20.0, segments[0].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
820 ASSERT_NEAR(45.0, segments[0].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
821 ASSERT_NEAR(10.0, segments[0].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
822 ASSERT_NEAR(10.0, segments[0].second.GetY(), DELTA_MAX); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
823 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
824 ASSERT_NEAR(52.0, segments[1].first.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
825 ASSERT_NEAR(70.0, segments[1].second.GetX(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
826 ASSERT_NEAR(10.0, segments[1].first.GetY(), DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
827 ASSERT_NEAR(10.0, segments[1].second.GetY(), DELTA_MAX); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
828 } |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
829 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
830 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
831 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
832 TEST(StructureSet2, ConvertListOfSlabsToSegments_Complete_Empty) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
833 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
834 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
835 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
836 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
837 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
838 |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
839 ASSERT_NO_THROW(ConvertListOfSlabsToSegments(segments, slabCuts, 0)); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
840 ASSERT_EQ(0u, segments.size()); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
841 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
842 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
843 TEST(StructureSet2, ConvertListOfSlabsToSegments_Complete_Regular) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
844 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
845 std::vector< RtStructRectanglesInSlab > slabCuts; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
846 std::vector<std::pair<double, RectangleBoundaryKind> > boundaries; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
847 size_t totalRectCount = FillTestRectangleList(slabCuts); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
848 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
849 std::vector< std::pair<ScenePoint2D, ScenePoint2D> > segments; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
850 |
1006
4f28d9459e31
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
Benjamin Golinvaux <bgo@osimis.io>
parents:
999
diff
changeset
|
851 ASSERT_NO_THROW(ConvertListOfSlabsToSegments(segments, slabCuts, totalRectCount)); |
999
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
852 ASSERT_EQ(60u, segments.size()); |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
853 |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
854 size_t i = 0; |
2d69b8bee484
Added tests for Dicom structure set classes (loaders and utils)
Benjamin Golinvaux <bgo@osimis.io>
parents:
diff
changeset
|
855 |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
856 ASSERT_NEAR(segments[i].first.GetX(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
857 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
858 ASSERT_NEAR(segments[i].second.GetX(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
859 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
860 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
861 ASSERT_NEAR(segments[i].first.GetX(), 31.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
862 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
863 ASSERT_NEAR(segments[i].second.GetX(), 31.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
864 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
865 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
866 ASSERT_NEAR(segments[i].first.GetX(), 36.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
867 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
868 ASSERT_NEAR(segments[i].second.GetX(), 36.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
869 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
870 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
871 ASSERT_NEAR(segments[i].first.GetX(), 50.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
872 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
873 ASSERT_NEAR(segments[i].second.GetX(), 50.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
874 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
875 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
876 ASSERT_NEAR(segments[i].first.GetX(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
877 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
878 ASSERT_NEAR(segments[i].second.GetX(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
879 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
880 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
881 ASSERT_NEAR(segments[i].first.GetX(), 45.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
882 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
883 ASSERT_NEAR(segments[i].second.GetX(), 45.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
884 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
885 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
886 ASSERT_NEAR(segments[i].first.GetX(), 52.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
887 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
888 ASSERT_NEAR(segments[i].second.GetX(), 52.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
889 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
890 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
891 ASSERT_NEAR(segments[i].first.GetX(), 70.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
892 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
893 ASSERT_NEAR(segments[i].second.GetX(), 70.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
894 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
895 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
896 ASSERT_NEAR(segments[i].first.GetX(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
897 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
898 ASSERT_NEAR(segments[i].second.GetX(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
899 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
900 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
901 ASSERT_NEAR(segments[i].first.GetX(), 32.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
902 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
903 ASSERT_NEAR(segments[i].second.GetX(), 32.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
904 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
905 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
906 ASSERT_NEAR(segments[i].first.GetX(), 35.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
907 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
908 ASSERT_NEAR(segments[i].second.GetX(), 35.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
909 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
910 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
911 ASSERT_NEAR(segments[i].first.GetX(), 44.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
912 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
913 ASSERT_NEAR(segments[i].second.GetX(), 44.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
914 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
915 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
916 ASSERT_NEAR(segments[i].first.GetX(), 60.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
917 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
918 ASSERT_NEAR(segments[i].second.GetX(), 60.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
919 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
920 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
921 ASSERT_NEAR(segments[i].first.GetX(), 75.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
922 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
923 ASSERT_NEAR(segments[i].second.GetX(), 75.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
924 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
925 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
926 ASSERT_NEAR(segments[i].first.GetX(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
927 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
928 ASSERT_NEAR(segments[i].second.GetX(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
929 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
930 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
931 ASSERT_NEAR(segments[i].first.GetX(), 41.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
932 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
933 ASSERT_NEAR(segments[i].second.GetX(), 41.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
934 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
935 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
936 ASSERT_NEAR(segments[i].first.GetX(), 46.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
937 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
938 ASSERT_NEAR(segments[i].second.GetX(), 46.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
939 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
940 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
941 ASSERT_NEAR(segments[i].first.GetX(), 80.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
942 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
943 ASSERT_NEAR(segments[i].second.GetX(), 80.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
944 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
945 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
946 ASSERT_NEAR(segments[i].first.GetX(), 34.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
947 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
948 ASSERT_NEAR(segments[i].second.GetX(), 34.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
949 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
950 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
951 ASSERT_NEAR(segments[i].first.GetX(), 42.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
952 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
953 ASSERT_NEAR(segments[i].second.GetX(), 42.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
954 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
955 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
956 ASSERT_NEAR(segments[i].first.GetX(), 90.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
957 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
958 ASSERT_NEAR(segments[i].second.GetX(), 90.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
959 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
960 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
961 ASSERT_NEAR(segments[i].first.GetX(), 96.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
962 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
963 ASSERT_NEAR(segments[i].second.GetX(), 96.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
964 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
965 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
966 ASSERT_NEAR(segments[i].first.GetX(), 1.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
967 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
968 ASSERT_NEAR(segments[i].second.GetX(), 1.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
969 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
970 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
971 ASSERT_NEAR(segments[i].first.GetX(), 33.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
972 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
973 ASSERT_NEAR(segments[i].second.GetX(), 33.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
974 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
975 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
976 ASSERT_NEAR(segments[i].first.GetX(), 40.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
977 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
978 ASSERT_NEAR(segments[i].second.GetX(), 40.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
979 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
980 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
981 ASSERT_NEAR(segments[i].first.GetX(), 43.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
982 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
983 ASSERT_NEAR(segments[i].second.GetX(), 43.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
984 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
985 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
986 ASSERT_NEAR(segments[i].first.GetX(), 51.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
987 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
988 ASSERT_NEAR(segments[i].second.GetX(), 51.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
989 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
990 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
991 ASSERT_NEAR(segments[i].first.GetX(), 61.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
992 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
993 ASSERT_NEAR(segments[i].second.GetX(), 61.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
994 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
995 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
996 ASSERT_NEAR(segments[i].first.GetX(), 76.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
997 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
998 ASSERT_NEAR(segments[i].second.GetX(), 76.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
999 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1000 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1001 ASSERT_NEAR(segments[i].first.GetX(), 95.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1002 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1003 ASSERT_NEAR(segments[i].second.GetX(), 95.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1004 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1005 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1006 ASSERT_NEAR(segments[i].first.GetX(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1007 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1008 ASSERT_NEAR(segments[i].second.GetX(), 31.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1009 ASSERT_NEAR(segments[i].second.GetY(), 0.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1010 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1011 ASSERT_NEAR(segments[i].first.GetX(), 36.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1012 ASSERT_NEAR(segments[i].first.GetY(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1013 ASSERT_NEAR(segments[i].second.GetX(), 50.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1014 ASSERT_NEAR(segments[i].second.GetY(), 0.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1015 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1016 ASSERT_NEAR(segments[i].first.GetX(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1017 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1018 ASSERT_NEAR(segments[i].second.GetX(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1019 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1020 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1021 ASSERT_NEAR(segments[i].first.GetX(), 31.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1022 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1023 ASSERT_NEAR(segments[i].second.GetX(), 36.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1024 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1025 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1026 ASSERT_NEAR(segments[i].first.GetX(), 45.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1027 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1028 ASSERT_NEAR(segments[i].second.GetX(), 50.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1029 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1030 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1031 ASSERT_NEAR(segments[i].first.GetX(), 52.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1032 ASSERT_NEAR(segments[i].first.GetY(), 5.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1033 ASSERT_NEAR(segments[i].second.GetX(), 70.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1034 ASSERT_NEAR(segments[i].second.GetY(), 5.0000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1035 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1036 ASSERT_NEAR(segments[i].first.GetX(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1037 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1038 ASSERT_NEAR(segments[i].second.GetX(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1039 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1040 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1041 ASSERT_NEAR(segments[i].first.GetX(), 32.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1042 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1043 ASSERT_NEAR(segments[i].second.GetX(), 35.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1044 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1045 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1046 ASSERT_NEAR(segments[i].first.GetX(), 44.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1047 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1048 ASSERT_NEAR(segments[i].second.GetX(), 45.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1049 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1050 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1051 ASSERT_NEAR(segments[i].first.GetX(), 52.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1052 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1053 ASSERT_NEAR(segments[i].second.GetX(), 60.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1054 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1055 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1056 ASSERT_NEAR(segments[i].first.GetX(), 70.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1057 ASSERT_NEAR(segments[i].first.GetY(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1058 ASSERT_NEAR(segments[i].second.GetX(), 75.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1059 ASSERT_NEAR(segments[i].second.GetY(), 10.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1060 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1061 ASSERT_NEAR(segments[i].first.GetX(), 0.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1062 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1063 ASSERT_NEAR(segments[i].second.GetX(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1064 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1065 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1066 ASSERT_NEAR(segments[i].first.GetX(), 32.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1067 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1068 ASSERT_NEAR(segments[i].second.GetX(), 35.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1069 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1070 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1071 ASSERT_NEAR(segments[i].first.GetX(), 41.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1072 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1073 ASSERT_NEAR(segments[i].second.GetX(), 44.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1074 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1075 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1076 ASSERT_NEAR(segments[i].first.GetX(), 46.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1077 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1078 ASSERT_NEAR(segments[i].second.GetX(), 60.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1079 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1080 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1081 ASSERT_NEAR(segments[i].first.GetX(), 75.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1082 ASSERT_NEAR(segments[i].first.GetY(), 15.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1083 ASSERT_NEAR(segments[i].second.GetX(), 80.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1084 ASSERT_NEAR(segments[i].second.GetY(), 15.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1085 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1086 ASSERT_NEAR(segments[i].first.GetX(), 10.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1087 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1088 ASSERT_NEAR(segments[i].second.GetX(), 34.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1089 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1090 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1091 ASSERT_NEAR(segments[i].first.GetX(), 41.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1092 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1093 ASSERT_NEAR(segments[i].second.GetX(), 42.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1094 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1095 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1096 ASSERT_NEAR(segments[i].first.GetX(), 46.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1097 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1098 ASSERT_NEAR(segments[i].second.GetX(), 80.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1099 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1100 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1101 ASSERT_NEAR(segments[i].first.GetX(), 90.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1102 ASSERT_NEAR(segments[i].first.GetY(), 20.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1103 ASSERT_NEAR(segments[i].second.GetX(), 96.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1104 ASSERT_NEAR(segments[i].second.GetY(), 20.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1105 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1106 ASSERT_NEAR(segments[i].first.GetX(), 1.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1107 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1108 ASSERT_NEAR(segments[i].second.GetX(), 33.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1109 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1110 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1111 ASSERT_NEAR(segments[i].first.GetX(), 34.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1112 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1113 ASSERT_NEAR(segments[i].second.GetX(), 40.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1114 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1115 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1116 ASSERT_NEAR(segments[i].first.GetX(), 42.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1117 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1118 ASSERT_NEAR(segments[i].second.GetX(), 43.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1119 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1120 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1121 ASSERT_NEAR(segments[i].first.GetX(), 51.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1122 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1123 ASSERT_NEAR(segments[i].second.GetX(), 61.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1124 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1125 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1126 ASSERT_NEAR(segments[i].first.GetX(), 76.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1127 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1128 ASSERT_NEAR(segments[i].second.GetX(), 90.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1129 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1130 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1131 ASSERT_NEAR(segments[i].first.GetX(), 95.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1132 ASSERT_NEAR(segments[i].first.GetY(), 25.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1133 ASSERT_NEAR(segments[i].second.GetX(), 96.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1134 ASSERT_NEAR(segments[i].second.GetY(), 25.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1135 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1136 ASSERT_NEAR(segments[i].first.GetX(), 1.0000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1137 ASSERT_NEAR(segments[i].first.GetY(), 30.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1138 ASSERT_NEAR(segments[i].second.GetX(), 33.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1139 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1140 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1141 ASSERT_NEAR(segments[i].first.GetX(), 40.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1142 ASSERT_NEAR(segments[i].first.GetY(), 30.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1143 ASSERT_NEAR(segments[i].second.GetX(), 43.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1144 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1145 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1146 ASSERT_NEAR(segments[i].first.GetX(), 51.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1147 ASSERT_NEAR(segments[i].first.GetY(), 30.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1148 ASSERT_NEAR(segments[i].second.GetX(), 61.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1149 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1150 i++; |
1895
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1151 ASSERT_NEAR(segments[i].first.GetX(), 76.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1152 ASSERT_NEAR(segments[i].first.GetY(), 30.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1153 ASSERT_NEAR(segments[i].second.GetX(), 95.000000000000000, DELTA_MAX); |
14c8f339d480
removed redundant definitions Point2D, Point3D and Vector3D from DicomStructureSetUtils.h
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1894
diff
changeset
|
1154 ASSERT_NEAR(segments[i].second.GetY(), 30.000000000000000, DELTA_MAX); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1155 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1156 |
1880
93c3f9234286
simplifying TestStructureSet.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1877
diff
changeset
|
1157 #if defined(BGO_ENABLE_DICOMSTRUCTURESETLOADER2) && (ORTHANC_SANDBOXED != 1) |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
1158 |
1834
126522623e20
replaced OrthancStone::DicomPath by new class Orthanc::DicomPath from orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1742
diff
changeset
|
1159 #include <SystemToolbox.h> |
126522623e20
replaced OrthancStone::DicomPath by new class Orthanc::DicomPath from orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1742
diff
changeset
|
1160 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1161 TEST(StructureSet2, ReadFromJsonPart2) |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1162 { |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1163 DicomStructureSet2 structureSet; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1164 std::string jsonText; |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1165 |
1834
126522623e20
replaced OrthancStone::DicomPath by new class Orthanc::DicomPath from orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1742
diff
changeset
|
1166 Orthanc::SystemToolbox::ReadFile(jsonText, "72c773ac-5059f2c4-2e6a9120-4fd4bca1-45701661.json"); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1167 |
1834
126522623e20
replaced OrthancStone::DicomPath by new class Orthanc::DicomPath from orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1742
diff
changeset
|
1168 FullOrthancDataset dicom(jsonText); |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1169 structureSet.Clear(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1170 |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1171 structureSet.FillStructuresFromDataset(dicom); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1172 structureSet.ComputeDependentProperties(); |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1173 |
1881
a05529952510
fix build of unit tests in SDL project
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1880
diff
changeset
|
1174 //const std::vector<DicomStructure2>& structures = structureSet.structures_; |
1010
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1175 } |
efe1c44628a1
Fixed mysterious revert of a previous change + converted a .cpp to unix LF
Benjamin Golinvaux <bgo@osimis.io>
parents:
1006
diff
changeset
|
1176 |
1019
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
1177 #endif |
29f5f2031310
Added a way to specificy which structures are to be initially displayed (the
Benjamin Golinvaux <bgo@osimis.io>
parents:
1012
diff
changeset
|
1178 // BGO_ENABLE_DICOMSTRUCTURESETLOADER2 |
1894
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1179 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1180 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1181 TEST(StructureSet, ReadFromJson) |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1182 { |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1183 FullOrthancDataset dicom(Orthanc::EmbeddedResources::GetFileResourceBuffer(Orthanc::EmbeddedResources::RT_STRUCT_00), |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1184 Orthanc::EmbeddedResources::GetFileResourceSize(Orthanc::EmbeddedResources::RT_STRUCT_00)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1185 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1186 DicomStructureSet rtstruct(dicom); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1187 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1188 ASSERT_DOUBLE_EQ(0.0, rtstruct.GetEstimatedNormal() [0]); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1189 ASSERT_DOUBLE_EQ(0.0, rtstruct.GetEstimatedNormal() [1]); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1190 ASSERT_DOUBLE_EQ(1.0, rtstruct.GetEstimatedNormal() [2]); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1191 ASSERT_DOUBLE_EQ(3.0, rtstruct.GetEstimatedSliceThickness()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1192 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1193 // (0x3006, 0x0080) seq. size |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1194 ASSERT_EQ(7u, rtstruct.GetStructuresCount()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1195 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1196 // (0x3006, 0x0080)[i]/(0x3006, 0x00a4) |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1197 for (size_t i = 0; i < 5; ++i) |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1198 { |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1199 ASSERT_EQ("ORGAN", rtstruct.GetStructureInterpretation(i)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1200 } |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1201 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1202 ASSERT_EQ("EXTERNAL", rtstruct.GetStructureInterpretation(5)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1203 ASSERT_EQ("PTV", rtstruct.GetStructureInterpretation(6)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1204 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1205 // (0x3006, 0x0020)[i]/(0x3006, 0x0026) |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1206 ASSERT_EQ("LN300", rtstruct.GetStructureName(0)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1207 ASSERT_EQ("Cortical Bone", rtstruct.GetStructureName(1)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1208 ASSERT_EQ("Adipose", rtstruct.GetStructureName(2)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1209 ASSERT_EQ("CB2-50%", rtstruct.GetStructureName(3)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1210 ASSERT_EQ("Water", rtstruct.GetStructureName(4)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1211 ASSERT_EQ("External", rtstruct.GetStructureName(5)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1212 ASSERT_EQ("PTV", rtstruct.GetStructureName(6)); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1213 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1214 // (0x3006, 0x0039)[i]/(0x3006, 0x002a) |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1215 ASSERT_EQ(255, rtstruct.GetStructureColor(0).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1216 ASSERT_EQ(0, rtstruct.GetStructureColor(0).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1217 ASSERT_EQ(0, rtstruct.GetStructureColor(0).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1218 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1219 ASSERT_EQ(0, rtstruct.GetStructureColor(1).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1220 ASSERT_EQ(255, rtstruct.GetStructureColor(1).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1221 ASSERT_EQ(255, rtstruct.GetStructureColor(1).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1222 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1223 ASSERT_EQ(255, rtstruct.GetStructureColor(2).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1224 ASSERT_EQ(0, rtstruct.GetStructureColor(2).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1225 ASSERT_EQ(255, rtstruct.GetStructureColor(2).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1226 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1227 ASSERT_EQ(0, rtstruct.GetStructureColor(3).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1228 ASSERT_EQ(0, rtstruct.GetStructureColor(3).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1229 ASSERT_EQ(255, rtstruct.GetStructureColor(3).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1230 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1231 ASSERT_EQ(0, rtstruct.GetStructureColor(4).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1232 ASSERT_EQ(128, rtstruct.GetStructureColor(4).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1233 ASSERT_EQ(255, rtstruct.GetStructureColor(4).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1234 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1235 ASSERT_EQ(0, rtstruct.GetStructureColor(5).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1236 ASSERT_EQ(128, rtstruct.GetStructureColor(5).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1237 ASSERT_EQ(0, rtstruct.GetStructureColor(5).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1238 |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1239 ASSERT_EQ(255, rtstruct.GetStructureColor(6).GetRed()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1240 ASSERT_EQ(0, rtstruct.GetStructureColor(6).GetGreen()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1241 ASSERT_EQ(255, rtstruct.GetStructureColor(6).GetBlue()); |
438071a29f77
xor polygon filler for holes in rt-struct
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1893
diff
changeset
|
1242 } |