annotate Sphinx/source/plugins/webviewer.rst @ 28:dc235678897c

webviewer
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 20 Jul 2016 10:48:43 +0200
parents c23f02a64caf
children 1a6c863cf364
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
24
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 .. _webviewer:
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 Web Viewer plugin
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 =================
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6
27
c23f02a64caf postgresql
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 24
diff changeset
7 .. contents::
c23f02a64caf postgresql
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 24
diff changeset
8
24
25fa874803ab plugins inside book
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 This **official** plugin extends Orthanc with a Web viewer of medical images.
27
c23f02a64caf postgresql
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 24
diff changeset
10
c23f02a64caf postgresql
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 24
diff changeset
11 For general information, check out the `official homepage of the
c23f02a64caf postgresql
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 24
diff changeset
12 plugin <http://www.orthanc-server.com/static.php?page=web-viewer>`__.
28
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
13
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
14
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
15 Compilation
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
16 -----------
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
17
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
18 .. highlight:: text
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
19
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
20 The procedure to compile these plugins is similar of that for the
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
21 :ref:`core of Orthanc <compiling>`. The following commands should work
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
22 for every UNIX-like distribution (including GNU/Linux)::
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
23
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
24 $ mkdir Build
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
25 $ cd Build
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
26 $ cmake .. -DSTATIC_BUILD=ON
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
27 $ make
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
28
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
29 The compilation will produce a shared library ``OrthancWebViewer``
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
30 that contains the Web viewer plugin. Pre-compiled binaries for
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
31 Microsoft Windows `are also available
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
32 <http://www.orthanc-server.com/browse.php?path=/plugin-webviewer>`__.
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
33
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
34
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
35 Usage
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
36 -----
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
37
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
38 .. highlight:: json
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
39
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
40 You of course first have to :ref:`install Orthanc <compiling>`. Once
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
41 Orthanc is installed, you must change the :ref:`configuration file
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
42 <configuration>` to tell Orthanc where it can find the plugin: This is
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
43 done by properly modifying the ``Plugins`` option. You could for
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
44 instance use the following configuration file::
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
45
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
46 {
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
47 "Name" : "MyOrthanc",
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
48 [...]
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
49 "Plugins" : [
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
50 "/home/user/OrthancWebViewer/Build/libOrthancWebViewer.so"
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
51 ]
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
52 }
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
53
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
54 .. highlight:: text
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
55
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
56 Orthanc must of course be restarted after the modification of its
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
57 configuration file. The log will contain an output similar to::
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
58
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
59 # Orthanc ./Configuration.json
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
60 W0226 16:59:10.480226 7906 main.cpp:636] Orthanc version: mainline
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
61 [...]
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
62 W0226 16:59:10.519664 7906 PluginsManager.cpp:258] Registering plugin 'web-viewer' (version 1.0)
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
63 W0226 16:59:10.519696 7906 PluginsManager.cpp:148] Initializing the Web viewer
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
64 W0226 16:59:10.520004 7906 PluginsManager.cpp:148] Web viewer using 6 threads for the decoding of the DICOM images
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
65 W0226 16:59:10.520021 7906 PluginsManager.cpp:148] Storing the cache of the Web viewer in folder: OrthancStorage/WebViewerCache
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
66 W0226 16:59:10.522011 7906 PluginsManager.cpp:148] Web viewer using a cache of 100 MB
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
67 [...]
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
68 W0226 16:59:10.530807 7906 main.cpp:516] HTTP server listening on port: 8042
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
69 W0226 16:59:10.581029 7906 main.cpp:526] DICOM server listening on port: 4242
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
70 W0226 16:59:10.581066 7906 main.cpp:533] Orthanc has started
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
71
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
72 Once a :ref:`DICOM series <model-world>` is opened using Orthanc
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
73 Explorer, a yellow button entitled ``Orthanc Web Viewer`` will show
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
74 up. It will open the Web viewer for that particular series. See also
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
75 the demonstration video on `official homepage of the plugin
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
76 <http://www.orthanc-server.com/static.php?page=web-viewer>`__.
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
77
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
78
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
79 Advanced options
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
80 ----------------
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
81
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
82 .. highlight:: json
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
83
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
84 The configuration of the Web viewer can be fine-tuned by adding some options::
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
85
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
86 {
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
87 "Name" : "MyOrthanc",
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
88 [...]
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
89 "Plugins" : [
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
90 "/home/user/OrthancWebViewer/Build/libOrthancWebViewer.so"
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
91 ],
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
92 "WebViewer" : {
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
93 "CachePath" : "WebViewerCache",
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
94 "CacheSize" : 10,
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
95 "Threads" : 4
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
96 }
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
97 }
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
98
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
99 * ``CachePath`` specifies the location of the cache of the Web
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
100 viewer. By default, the cache is located inside the storage
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
101 directory of Orthanc.
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
102 * ``CacheSize`` specifies the maximum size for the cached images, in
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
103 megabytes. By default, a cache of 100 MB is used.
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
104 * ``Threads`` specifies the number of threads that are used by the
dc235678897c webviewer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 27
diff changeset
105 plugin to decode the DICOM images.