Mercurial > hg > orthanc-stone
comparison StoneWebViewer/Plugin/Plugin.cpp @ 1519:22d1bd085c19
split STONE_BINARIES into two different vars for both
StoneWebViewer and RtViewer
+ fixed docker build
+ embed of RtViewer files
+ serving of RtViewer files
+ Orthanc explorer extension to open a series in
the RtViewer : sibling series will be traversed and the
first DOSE/STRUCT will be used.
WARNING: needs work for PT and to allow for missing dose
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Fri, 31 Jul 2020 12:51:28 +0200 |
parents | dd1d1cc0575d |
children | 61023b0d39c8 |
comparison
equal
deleted
inserted
replaced
1518:433cf964838d | 1519:22d1bd085c19 |
---|---|
189 std::string explorer; | 189 std::string explorer; |
190 Orthanc::EmbeddedResources::GetFileResource( | 190 Orthanc::EmbeddedResources::GetFileResource( |
191 explorer, Orthanc::EmbeddedResources::ORTHANC_EXPLORER); | 191 explorer, Orthanc::EmbeddedResources::ORTHANC_EXPLORER); |
192 OrthancPluginExtendOrthancExplorer(OrthancPlugins::GetGlobalContext(), explorer.c_str()); | 192 OrthancPluginExtendOrthancExplorer(OrthancPlugins::GetGlobalContext(), explorer.c_str()); |
193 | 193 |
194 // Stone Web Viewer files | |
195 // --------------------- | |
194 OrthancPlugins::RegisterRestCallback | 196 OrthancPlugins::RegisterRestCallback |
195 <ServeEmbeddedFile<Orthanc::EmbeddedResources::STONE_WEB_VIEWER_WASM> > | 197 <ServeEmbeddedFile<Orthanc::EmbeddedResources::STONE_WEB_VIEWER_WASM> > |
196 ("/stone-webviewer/StoneWebViewer.wasm", true); | 198 ("/stone-webviewer/StoneWebViewer.wasm", true); |
197 | 199 |
198 OrthancPlugins::RegisterRestCallback | 200 OrthancPlugins::RegisterRestCallback |
209 | 211 |
210 OrthancPlugins::RegisterRestCallback | 212 OrthancPlugins::RegisterRestCallback |
211 <ServeEmbeddedFolder<Orthanc::EmbeddedResources::WEB_APPLICATION> > | 213 <ServeEmbeddedFolder<Orthanc::EmbeddedResources::WEB_APPLICATION> > |
212 ("/stone-webviewer/(.*)", true); | 214 ("/stone-webviewer/(.*)", true); |
213 | 215 |
216 // RtViewer files below. | |
217 // --------------------- | |
218 // we do not serve the whole directory at once (with ServeEmbeddedFolder) | |
219 // because it contains uppercase characters that are forbidden by the | |
220 // resource embedding system | |
221 | |
222 OrthancPlugins::RegisterRestCallback | |
223 <ServeEmbeddedFile<Orthanc::EmbeddedResources::RT_VIEWER_WASM_JS> > | |
224 ("/stone-rtviewer/RtViewerWasm.js", true); | |
225 | |
226 OrthancPlugins::RegisterRestCallback | |
227 <ServeEmbeddedFile<Orthanc::EmbeddedResources::RT_VIEWER_WASM> > | |
228 ("/stone-rtviewer/RtViewerWasm.wasm", true); | |
229 | |
230 OrthancPlugins::RegisterRestCallback | |
231 <ServeEmbeddedFile<Orthanc::EmbeddedResources::RT_VIEWER_WASM_APP_JS> > | |
232 ("/stone-rtviewer/RtViewerWasmApp.js", true); | |
233 | |
234 OrthancPlugins::RegisterRestCallback | |
235 <ServeEmbeddedFile<Orthanc::EmbeddedResources::RT_VIEWER_INDEX_HTML> > | |
236 ("/stone-rtviewer/index.html", true); | |
237 | |
214 OrthancPluginRegisterOnChangeCallback(context, OnChangeCallback); | 238 OrthancPluginRegisterOnChangeCallback(context, OnChangeCallback); |
215 } | 239 } |
216 catch (...) | 240 catch (...) |
217 { | 241 { |
218 OrthancPlugins::LogError("Exception while initializing the Stone Web viewer plugin"); | 242 OrthancPlugins::LogError("Exception while initializing the Stone Web viewer plugin"); |