Mercurial > hg > orthanc
annotate UnitTestsSources/ImageTests.cpp @ 2507:99116ed6f38c
invalidate DicomCache when deleting instance
author | amazy |
---|---|
date | Mon, 26 Mar 2018 18:31:40 +0200 |
parents | 878b59270859 |
children | 52217dc47a4e |
rev | line source |
---|---|
827
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
1 /** |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
2 * Orthanc - A Lightweight, RESTful DICOM Store |
1900 | 3 * Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics |
1288
6e7e5ed91c2d
upgrade to year 2015
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
967
diff
changeset
|
4 * Department, University Hospital of Liege, Belgium |
2447
878b59270859
upgrade to year 2018
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2381
diff
changeset
|
5 * Copyright (C) 2017-2018 Osimis S.A., Belgium |
827
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
6 * |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
7 * This program is free software: you can redistribute it and/or |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
8 * modify it under the terms of the GNU General Public License as |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
9 * published by the Free Software Foundation, either version 3 of the |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
10 * License, or (at your option) any later version. |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
11 * |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
12 * In addition, as a special exception, the copyright holders of this |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
13 * program give permission to link the code of its release with the |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
14 * OpenSSL project's "OpenSSL" library (or with modified versions of it |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
15 * that use the same license as the "OpenSSL" library), and distribute |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
16 * the linked executables. You must obey the GNU General Public License |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
17 * in all respects for all of the code used other than "OpenSSL". If you |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
18 * modify file(s) with this exception, you may extend this exception to |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
19 * your version of the file(s), but you are not obligated to do so. If |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
20 * you do not wish to do so, delete this exception statement from your |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
21 * version. If you delete this exception statement from all source files |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
22 * in the program, then also delete it here. |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
23 * |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
24 * This program is distributed in the hope that it will be useful, but |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
25 * WITHOUT ANY WARRANTY; without even the implied warranty of |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
26 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
27 * General Public License for more details. |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
28 * |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
29 * You should have received a copy of the GNU General Public License |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
30 * along with this program. If not, see <http://www.gnu.org/licenses/>. |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
31 **/ |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
32 |
3d6f9b7d0add
precompiled headers in unit tests
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
803
diff
changeset
|
33 |
831
84513f2ee1f3
pch for unit tests and server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
827
diff
changeset
|
34 #include "PrecompiledHeadersUnitTests.h" |
368 | 35 #include "gtest/gtest.h" |
36 | |
1612
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
37 #include "../Core/Images/Font.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
38 #include "../Core/Images/Image.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
39 #include "../Core/Images/ImageProcessing.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
40 #include "../Core/Images/JpegReader.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
41 #include "../Core/Images/JpegWriter.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
42 #include "../Core/Images/PngReader.h" |
96582230ddcb
Core/ImageFormats folder renamed as Core/Images
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1611
diff
changeset
|
43 #include "../Core/Images/PngWriter.h" |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
44 #include "../Core/Toolbox.h" |
2142 | 45 #include "../Core/TemporaryFile.h" |
2381
b8969010b534
uncoupling DCMTK primitives from Orthanc::Configuration
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2244
diff
changeset
|
46 #include "../OrthancServer/OrthancInitialization.h" // For the FontRegistry |
1610
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
47 |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
48 #include <stdint.h> |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
49 |
368 | 50 |
51 TEST(PngWriter, ColorPattern) | |
52 { | |
53 Orthanc::PngWriter w; | |
1654
3727a09e7b53
fix some icc warnings
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1612
diff
changeset
|
54 unsigned int width = 17; |
3727a09e7b53
fix some icc warnings
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1612
diff
changeset
|
55 unsigned int height = 61; |
3727a09e7b53
fix some icc warnings
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1612
diff
changeset
|
56 unsigned int pitch = width * 3; |
368 | 57 |
58 std::vector<uint8_t> image(height * pitch); | |
1654
3727a09e7b53
fix some icc warnings
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1612
diff
changeset
|
59 for (unsigned int y = 0; y < height; y++) |
368 | 60 { |
61 uint8_t *p = &image[0] + y * pitch; | |
1654
3727a09e7b53
fix some icc warnings
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1612
diff
changeset
|
62 for (unsigned int x = 0; x < width; x++, p += 3) |
368 | 63 { |
64 p[0] = (y % 3 == 0) ? 255 : 0; | |
65 p[1] = (y % 3 == 1) ? 255 : 0; | |
66 p[2] = (y % 3 == 2) ? 255 : 0; | |
67 } | |
68 } | |
69 | |
1916 | 70 Orthanc::ImageAccessor accessor; |
71 accessor.AssignReadOnly(Orthanc::PixelFormat_RGB24, width, height, pitch, &image[0]); | |
72 | |
73 w.WriteToFile("UnitTestsResults/ColorPattern.png", accessor); | |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
74 |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
75 std::string f, md5; |
2140 | 76 Orthanc::SystemToolbox::ReadFile(f, "UnitTestsResults/ColorPattern.png"); |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
77 Orthanc::Toolbox::ComputeMD5(md5, f); |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
78 ASSERT_EQ("604e785f53c99cae6ea4584870b2c41d", md5); |
368 | 79 } |
80 | |
81 TEST(PngWriter, Gray8Pattern) | |
82 { | |
83 Orthanc::PngWriter w; | |
84 int width = 17; | |
85 int height = 256; | |
86 int pitch = width; | |
87 | |
88 std::vector<uint8_t> image(height * pitch); | |
89 for (int y = 0; y < height; y++) | |
90 { | |
91 uint8_t *p = &image[0] + y * pitch; | |
92 for (int x = 0; x < width; x++, p++) | |
93 { | |
94 *p = y; | |
95 } | |
96 } | |
97 | |
1916 | 98 Orthanc::ImageAccessor accessor; |
99 accessor.AssignReadOnly(Orthanc::PixelFormat_Grayscale8, width, height, pitch, &image[0]); | |
100 | |
101 w.WriteToFile("UnitTestsResults/Gray8Pattern.png", accessor); | |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
102 |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
103 std::string f, md5; |
2140 | 104 Orthanc::SystemToolbox::ReadFile(f, "UnitTestsResults/Gray8Pattern.png"); |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
105 Orthanc::Toolbox::ComputeMD5(md5, f); |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
106 ASSERT_EQ("5a9b98bea3d0a6d983980cc38bfbcdb3", md5); |
368 | 107 } |
108 | |
109 TEST(PngWriter, Gray16Pattern) | |
110 { | |
111 Orthanc::PngWriter w; | |
112 int width = 256; | |
113 int height = 256; | |
369
4632a044746e
simplification of the code
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
368
diff
changeset
|
114 int pitch = width * 2 + 16; |
368 | 115 |
116 std::vector<uint8_t> image(height * pitch); | |
369
4632a044746e
simplification of the code
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
368
diff
changeset
|
117 |
368 | 118 int v = 0; |
119 for (int y = 0; y < height; y++) | |
120 { | |
121 uint16_t *p = reinterpret_cast<uint16_t*>(&image[0] + y * pitch); | |
122 for (int x = 0; x < width; x++, p++, v++) | |
123 { | |
124 *p = v; | |
125 } | |
126 } | |
127 | |
1916 | 128 Orthanc::ImageAccessor accessor; |
129 accessor.AssignReadOnly(Orthanc::PixelFormat_Grayscale16, width, height, pitch, &image[0]); | |
130 w.WriteToFile("UnitTestsResults/Gray16Pattern.png", accessor); | |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
131 |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
132 std::string f, md5; |
2140 | 133 Orthanc::SystemToolbox::ReadFile(f, "UnitTestsResults/Gray16Pattern.png"); |
639
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
134 Orthanc::Toolbox::ComputeMD5(md5, f); |
51892be15618
fix for big endian architectures
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
632
diff
changeset
|
135 ASSERT_EQ("0785866a08bf0a02d2eeff87f658571c", md5); |
368 | 136 } |
455 | 137 |
138 TEST(PngWriter, EndToEnd) | |
139 { | |
140 Orthanc::PngWriter w; | |
1492 | 141 unsigned int width = 256; |
142 unsigned int height = 256; | |
143 unsigned int pitch = width * 2 + 16; | |
455 | 144 |
145 std::vector<uint8_t> image(height * pitch); | |
146 | |
147 int v = 0; | |
1492 | 148 for (unsigned int y = 0; y < height; y++) |
455 | 149 { |
150 uint16_t *p = reinterpret_cast<uint16_t*>(&image[0] + y * pitch); | |
1492 | 151 for (unsigned int x = 0; x < width; x++, p++, v++) |
455 | 152 { |
153 *p = v; | |
154 } | |
155 } | |
156 | |
1916 | 157 Orthanc::ImageAccessor accessor; |
158 accessor.AssignReadOnly(Orthanc::PixelFormat_Grayscale16, width, height, pitch, &image[0]); | |
159 | |
455 | 160 std::string s; |
1916 | 161 w.WriteToMemory(s, accessor); |
455 | 162 |
709 | 163 { |
164 Orthanc::PngReader r; | |
165 r.ReadFromMemory(s); | |
455 | 166 |
710 | 167 ASSERT_EQ(r.GetFormat(), Orthanc::PixelFormat_Grayscale16); |
709 | 168 ASSERT_EQ(r.GetWidth(), width); |
169 ASSERT_EQ(r.GetHeight(), height); | |
455 | 170 |
709 | 171 v = 0; |
1492 | 172 for (unsigned int y = 0; y < height; y++) |
709 | 173 { |
797
37adac56017a
ImageAccessor abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
711
diff
changeset
|
174 const uint16_t *p = reinterpret_cast<const uint16_t*>((const uint8_t*) r.GetConstBuffer() + y * r.GetPitch()); |
37adac56017a
ImageAccessor abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
711
diff
changeset
|
175 ASSERT_EQ(p, r.GetConstRow(y)); |
1492 | 176 for (unsigned int x = 0; x < width; x++, p++, v++) |
709 | 177 { |
178 ASSERT_EQ(*p, v); | |
179 } | |
180 } | |
181 } | |
182 | |
455 | 183 { |
2140 | 184 Orthanc::TemporaryFile tmp; |
185 Orthanc::SystemToolbox::WriteFile(s, tmp.GetPath()); | |
709 | 186 |
187 Orthanc::PngReader r2; | |
188 r2.ReadFromFile(tmp.GetPath()); | |
189 | |
710 | 190 ASSERT_EQ(r2.GetFormat(), Orthanc::PixelFormat_Grayscale16); |
709 | 191 ASSERT_EQ(r2.GetWidth(), width); |
192 ASSERT_EQ(r2.GetHeight(), height); | |
710 | 193 |
194 v = 0; | |
1492 | 195 for (unsigned int y = 0; y < height; y++) |
455 | 196 { |
797
37adac56017a
ImageAccessor abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
711
diff
changeset
|
197 const uint16_t *p = reinterpret_cast<const uint16_t*>((const uint8_t*) r2.GetConstBuffer() + y * r2.GetPitch()); |
37adac56017a
ImageAccessor abstraction
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
711
diff
changeset
|
198 ASSERT_EQ(p, r2.GetConstRow(y)); |
1492 | 199 for (unsigned int x = 0; x < width; x++, p++, v++) |
709 | 200 { |
201 ASSERT_EQ(*p, v); | |
202 } | |
455 | 203 } |
204 } | |
205 } | |
1602 | 206 |
207 | |
208 | |
209 | |
210 TEST(JpegWriter, Basic) | |
211 { | |
1604 | 212 std::string s; |
213 | |
1602 | 214 { |
2107 | 215 Orthanc::Image img(Orthanc::PixelFormat_Grayscale8, 16, 16, false); |
1604 | 216 for (unsigned int y = 0, value = 0; y < img.GetHeight(); y++) |
1602 | 217 { |
1608
adc6a5704cdb
OrthancPluginConvertPixelFormat
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1604
diff
changeset
|
218 uint8_t* p = reinterpret_cast<uint8_t*>(img.GetRow(y)); |
1604 | 219 for (unsigned int x = 0; x < img.GetWidth(); x++, p++) |
220 { | |
221 *p = value++; | |
222 } | |
223 } | |
224 | |
225 Orthanc::JpegWriter w; | |
1608
adc6a5704cdb
OrthancPluginConvertPixelFormat
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1604
diff
changeset
|
226 w.WriteToFile("UnitTestsResults/hello.jpg", img); |
1604 | 227 |
1608
adc6a5704cdb
OrthancPluginConvertPixelFormat
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1604
diff
changeset
|
228 w.WriteToMemory(s, img); |
2140 | 229 Orthanc::SystemToolbox::WriteFile(s, "UnitTestsResults/hello2.jpg"); |
1604 | 230 |
231 std::string t; | |
2140 | 232 Orthanc::SystemToolbox::ReadFile(t, "UnitTestsResults/hello.jpg"); |
1604 | 233 ASSERT_EQ(s.size(), t.size()); |
234 ASSERT_EQ(0, memcmp(s.c_str(), t.c_str(), s.size())); | |
235 } | |
236 | |
237 { | |
238 Orthanc::JpegReader r1, r2; | |
239 r1.ReadFromFile("UnitTestsResults/hello.jpg"); | |
1970 | 240 ASSERT_EQ(16u, r1.GetWidth()); |
241 ASSERT_EQ(16u, r1.GetHeight()); | |
1604 | 242 |
243 r2.ReadFromMemory(s); | |
1970 | 244 ASSERT_EQ(16u, r2.GetWidth()); |
245 ASSERT_EQ(16u, r2.GetHeight()); | |
1604 | 246 |
247 for (unsigned int y = 0; y < r1.GetHeight(); y++) | |
248 { | |
249 const uint8_t* p1 = reinterpret_cast<const uint8_t*>(r1.GetConstRow(y)); | |
250 const uint8_t* p2 = reinterpret_cast<const uint8_t*>(r2.GetConstRow(y)); | |
251 for (unsigned int x = 0; x < r1.GetWidth(); x++) | |
252 { | |
253 ASSERT_EQ(*p1, *p2); | |
254 } | |
1602 | 255 } |
256 } | |
257 } | |
1610
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
258 |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
259 |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
260 TEST(Font, Basic) |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
261 { |
2107 | 262 Orthanc::Image s(Orthanc::PixelFormat_RGB24, 640, 480, false); |
1610
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
263 memset(s.GetBuffer(), 0, s.GetPitch() * s.GetHeight()); |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
264 |
1970 | 265 ASSERT_GE(1u, Orthanc::Configuration::GetFontRegistry().GetSize()); |
1611
5e9b2aac8b89
fix for visual studio
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1610
diff
changeset
|
266 Orthanc::Configuration::GetFontRegistry().GetFont(0).Draw(s, "Hello world É\n\rComment ça va ?\nq", 50, 60, 255, 0, 0); |
1610
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
267 |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
268 Orthanc::PngWriter w; |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
269 w.WriteToFile("UnitTestsResults/font.png", s); |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
270 } |
2dff2bdffdb8
font support within Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1608
diff
changeset
|
271 |