view Applications/StoneWebViewer/NOTES.txt @ 2147:bea4e7900a47

upgraded jquery to 3.7.1 & axios to 1.7.5
author Alain Mazy <am@orthanc.team>
date Mon, 26 Aug 2024 17:59:20 +0200
parents 5653b6335642
children
line wrap: on
line source



Differences with Osimis Web viewer
==================================

- The images are retrieved using DICOMweb.


- In the Stone Web viewer, the individual instances are loaded on
  an as-needed basis, in order to reduce the network bandwidth usage.
  This contrasts with the Osimis Web viewer that loads the entire images
  in the background.


- The Stone Web viewer does not support Live Share that was available
  in old versions of the Osimis Web viewer.


- The Stone Web viewer displays a color block at the bottom-right of
  each viewport. A "red" color means that the current frame is still
  being loaded, so don't trust what is currently displayed. A "yellow"
  color means that the viewport displays a low-quality preview (JPEG).
  A "green" color means that the viewport contains an image with the
  same quality as the source DICOM image.


- The Stone Web viewer uses the DICOM identifiers, while the Osimis Web
  viewer uses the Orthanc identifiers.
  https://orthanc.uclouvain.be/book/faq/orthanc-ids.html

  In the Stone Web viewer, the studies are indexed by their "Study
  Instance UID" tag (0020,000d). The series are indexed by their
  "Series Instance UID" tag (0020,000e). To open a single series,
  the parent study must be provided.

  To open a single study:
  http://.../index.html?study=<StudyInstanceUID>

  To open a single series:
  http://.../index.html?study=<StudyInstanceUID>&series=<SeriesInstanceUID>


- In the Osimis Web viewer, the "OpenAllPatientStudies" configuration
  option can be provided to search Orthanc for all studies from
  patients with the same PatientID as the selected study, then display
  them.

  In the Stone Web viewer, the "OpenAllPatientStudies" configuration
  option is replaced by the single "patient" GET argument. This option
  contains a comma-separated list of "Patient ID" tag (0010,0020).

  To open all the studies of one patient:
  http://.../index.html?patient=<PatientID>

  To open all the studies of several patients:
  http://.../index.html?patient=<PatientID1>,<PatientID2>,...


- In the Osimis Web viewer, the "pickableStudyIds" parameter in the
  URL defines the list of studies that are available for display, and
  that are listed in the dropdown at the top-left of the interface.

  In the Stone Web viewer, "pickableStudyIds" is replaced by the
  single "study" GET argument, that is allowed to contain a
  comma-separated list of studies. The "series" parameter must not be
  provided in this case.

  To open a list of studies:
  http://.../index.html?study=<StudyInstanceUID1>,<StudyInstanceUID2>,...


- In the Osimis Web viewer, the "selectedStudyIds" parameter in the
  URL defines the list of studies that are selected in the dropdown at
  the top-left corner of the viewer (those studies are therefore
  displayed when the viewer starts).

  In the Stone Web viewer, "selectedStudyIds" is replaced by the
  "selectedStudies" GET argument, that is allowed to contain a
  comma-separated list of studies.

  To make a list of studies available, but display only one of those
  studies when the viewer starts, please use:
  http://.../index.html?study=<StudyInstanceUID1>,<StudyInstanceUID2>,...&selectedStudies=<StudyInstanceUID1>

  If the "selectedStudies" is not provided, then all the studies are
  displayed at the startup.


Minor changes
-------------

- Option "ShowInfoPanelButtonEnabled" in the Osimis Web viewer is
  named "ShowUserPreferencesButton" in the Stone Web viewer.

- Option "AlwaysShowNotForDiagnosticUsageDisclaimer" in the Osimis Web
  viewer is named "ShowNotForDiagnosticUsageDisclaimer" in the Stone
  Web viewer.

- The allowed values for option "ShowInfoPanelAtStartup" are "Always",
  "Never" of "User" (note the first character in upper case). In the
  Osimis Web viewer, these options were in lower case.



Authorization to the DICOMweb server (new in 2.0)
====================================

The function "stone.AddHttpHeader()" exposed in the WebAssembly API
can be used to add custom HTTP headers to each XMLHttpRequest that is
sent to the DICOMweb server. This notably gives the opportunity to
provide an authentication token using the "Authorization" HTTP header.

The Vue.js application will set the "Authorization" HTTP header to the
value "Bearer <token>" where "<token>" is value of the GET argument
"token" provided when opening "index.html". If the "token" GET
argument is absent, the "Authorization" header is not altered.

For instance, if the user opens the Stone Web viewer using the
following URL:

http://.../index.html?study=<StudyInstanceUID1>&token=Hello

Then each request to the DICOMweb server will contain the HTTP header:
"Authorization: Bearer Hello"


Additional options
==================

- If present in the URL, the "menu" argument can be used to set the
  default layout of the left-hand list of studies/series. Its allowed
  values are "hidden", "small", "grid" (default value at the study
  level), or "full" (default value at the series level). (new in Stone
  Web viewer 2.5)


Dynamic actions using messages
==============================

Some actions can be dynamically triggered in the Stone Web viewer from
another Web page. This is done by using the "window.postMessage()"
primitive of JavaScript:
https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage

Each message must be a JSON object containing at least the "type"
field. The latter field indicates the type of action to be triggered.

For security, the "ExpectedMessageOrigin" configuration option of the
Stone Web viewer must have been set to the expected origin of the
messages. Otherwise, the Stone Web viewer will reject the message.


Action of type "show-osirix-annotations"
----------------------------------------

This action loads a set of ROIs exported from OsiriX. The ROIs must
use the XML file format of OsiriX.

The parent DICOM study containing the annotation(s) must have been
loaded by the Stone Web viewer beforehand. The Stone Web viewer shall
automatically focus on one instance that is associated with the ROIs.

The JSON message must contain the following fields:

- "type" must be equal to "show-osirix-annotations"

- "xml" must contain the XML file generated by OsiriX

- "clear" is a Boolean to indicate whether to clear the annotations
  that have previously been opened.