annotate Sources/Plugin.cpp @ 13:7f77ea98e42c

sync
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 22 Nov 2023 08:01:42 +0100
parents fdb3093ab802
children ec47d2182ac6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 /**
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 * SPDX-FileCopyrightText: 2023 Sebastien Jodogne, UCLouvain, Belgium
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 * SPDX-License-Identifier: GPL-3.0-or-later
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 */
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 /**
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 * Kitware's VolView plugin for Orthanc
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8 * Copyright (C) 2023 Sebastien Jodogne, UCLouvain, Belgium
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 *
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 * This program is free software: you can redistribute it and/or
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 * modify it under the terms of the GNU General Public License as
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 * published by the Free Software Foundation, either version 3 of the
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 * License, or (at your option) any later version.
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 *
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 * This program is distributed in the hope that it will be useful, but
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 * WITHOUT ANY WARRANTY; without even the implied warranty of
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 * General Public License for more details.
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 *
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 * You should have received a copy of the GNU General Public License
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 * along with this program. If not, see <http://www.gnu.org/licenses/>.
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22 **/
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
25 #include "../Resources/Orthanc/Plugins/OrthancPluginCppWrapper.h"
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 #include <Logging.h>
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 #include <SystemToolbox.h>
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30 #include <EmbeddedResources.h>
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 #include <boost/thread/shared_mutex.hpp>
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 // Forward declaration
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35 void ReadStaticAsset(std::string& target,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 const std::string& path);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 /**
10
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 0
diff changeset
40 * As the VolView static assets are gzipped by the
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 0
diff changeset
41 * "EmbedStaticAssets.py" script, we use a cache to maintain the
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 0
diff changeset
42 * uncompressed assets in order to avoid multiple gzip decodings.
0
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43 **/
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44 class ResourcesCache : public boost::noncopyable
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 private:
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 typedef std::map<std::string, std::string*> Content;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 boost::shared_mutex mutex_;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 Content content_;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52 public:
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53 ~ResourcesCache()
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 for (Content::iterator it = content_.begin(); it != content_.end(); ++it)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 assert(it->second != NULL);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 delete it->second;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 void Answer(OrthancPluginRestOutput* output,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63 const std::string& path)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65 const std::string mime = Orthanc::EnumerationToString(Orthanc::SystemToolbox::AutodetectMimeType(path));
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
68 // Check whether the cache already contains the resource
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
69 boost::shared_lock<boost::shared_mutex> lock(mutex_);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
70
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
71 Content::const_iterator found = content_.find(path);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
72
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
73 if (found != content_.end())
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
74 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
75 assert(found->second != NULL);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
76 OrthancPluginAnswerBuffer(OrthancPlugins::GetGlobalContext(), output, found->second->c_str(), found->second->size(), mime.c_str());
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
77 return;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
78 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
79 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
80
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
81 // This resource has not been cached yet
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
82
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
83 std::unique_ptr<std::string> item(new std::string);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
84 ReadStaticAsset(*item, path);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
85 OrthancPluginAnswerBuffer(OrthancPlugins::GetGlobalContext(), output, item->c_str(), item->size(), mime.c_str());
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
86
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
87 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
88 // Store the resource into the cache
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
89 boost::unique_lock<boost::shared_mutex> lock(mutex_);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
90
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
91 if (content_.find(path) == content_.end())
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
92 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
93 content_[path] = item.release();
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
94 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
95 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
96 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
97 };
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
98
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
99
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
100 static ResourcesCache cache_;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
101
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
102 void ServeFile(OrthancPluginRestOutput* output,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
103 const char* url,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
104 const OrthancPluginHttpRequest* request)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
105 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
106 cache_.Answer(output, request->groups[0]);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
107 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
108
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
109 extern "C"
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
110 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
111 ORTHANC_PLUGINS_API int32_t OrthancPluginInitialize(OrthancPluginContext* context)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
112 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
113 OrthancPlugins::SetGlobalContext(context);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
114
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
115 /* Check the version of the Orthanc core */
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
116 if (OrthancPluginCheckVersion(OrthancPlugins::GetGlobalContext()) == 0)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
117 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
118 char info[1024];
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
119 sprintf(info, "Your version of Orthanc (%s) must be above %d.%d.%d to run this plugin",
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
120 OrthancPlugins::GetGlobalContext()->orthancVersion,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
121 ORTHANC_PLUGINS_MINIMAL_MAJOR_NUMBER,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
122 ORTHANC_PLUGINS_MINIMAL_MINOR_NUMBER,
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
123 ORTHANC_PLUGINS_MINIMAL_REVISION_NUMBER);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
124 OrthancPluginLogError(OrthancPlugins::GetGlobalContext(), info);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
125 return -1;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
126 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
127
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
128 #if ORTHANC_FRAMEWORK_VERSION_IS_ABOVE(1, 7, 2)
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
129 Orthanc::Logging::InitializePluginContext(context);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
130 #else
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
131 Orthanc::Logging::Initialize(context);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
132 #endif
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
133
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
134 OrthancPluginSetDescription(context, "Kitware's VolView for Orthanc.");
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
135
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
136 OrthancPlugins::RegisterRestCallback<ServeFile>("/volview/(.*)", true);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
137
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
138 // Extend the default Orthanc Explorer with custom JavaScript for VolView
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
139 std::string explorer;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
140 Orthanc::EmbeddedResources::GetFileResource(explorer, Orthanc::EmbeddedResources::ORTHANC_EXPLORER);
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
141 OrthancPluginExtendOrthancExplorer(OrthancPlugins::GetGlobalContext(), explorer.c_str());
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
142
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
143 return 0;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
144 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
145
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
146
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
147 ORTHANC_PLUGINS_API void OrthancPluginFinalize()
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
148 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
149 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
150
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
151
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
152 ORTHANC_PLUGINS_API const char* OrthancPluginGetName()
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
153 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
154 return "volview";
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
155 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
156
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
157
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
158 ORTHANC_PLUGINS_API const char* OrthancPluginGetVersion()
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
159 {
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
160 return ORTHANC_VOLVIEW_VERSION;
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
161 }
3f1cf4a8e31f initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
162 }