comparison Applications/Samples/WebAssembly/RtViewer/RtViewerWasmWrapper.js @ 1538:d1806b4e4839

moving OrthancStone/Samples/ as Applications/Samples/
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 11 Aug 2020 13:24:38 +0200
parents OrthancStone/Samples/WebAssembly/RtViewer/RtViewerWasmWrapper.js@244ad1e4e76a
children 8c5f9864545f
comparison
equal deleted inserted replaced
1537:de8cf5859e84 1538:d1806b4e4839
1
2 const Stone = function() {
3 this._InitializeViewport = undefined;
4 this._LoadOrthanc = undefined;
5 this._LoadDicomWeb = undefined;
6 };
7
8 Stone.prototype.Setup = function(Module) {
9 this._InitializeViewport = Module.cwrap('InitializeViewport', null, [ 'string' ]);
10 this._LoadOrthanc = Module.cwrap('LoadOrthanc', null, [ 'string', 'int' ]);
11 this._LoadDicomWeb = Module.cwrap('LoadDicomWeb', null, [ 'string', 'string', 'string', 'string', 'int' ]);
12 };
13
14 Stone.prototype.InitializeViewport = function(canvasId) {
15 this._InitializeViewport(canvasId);
16 };
17
18 Stone.prototype.LoadOrthanc = function(instance, frame) {
19 this._LoadOrthanc(instance, frame);
20 };
21
22 Stone.prototype.LoadDicomWeb = function(server, studyInstanceUid, seriesInstanceUid, sopInstanceUid, frame) {
23 this._LoadDicomWeb(server, studyInstanceUid, seriesInstanceUid, sopInstanceUid, frame);
24 };
25
26 var stone = new Stone();
27