copper3d 1.15.22 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/Loader/copperNrrdLoader.d.ts +1 -1
- package/dist/Renderer/baseRenderer.d.ts +2 -2
- package/dist/Renderer/baseRenderer.js +2 -2
- package/dist/Renderer/baseRenderer.js.map +1 -1
- package/dist/Renderer/copperMSceneRenderer.d.ts +2 -2
- package/dist/Renderer/copperMSceneRenderer.js +2 -2
- package/dist/Renderer/copperMSceneRenderer.js.map +1 -1
- package/dist/Renderer/copperRenderer.d.ts +4 -4
- package/dist/Renderer/copperRenderer.js +3 -3
- package/dist/Renderer/copperRenderer.js.map +1 -1
- package/dist/Renderer/copperRendererOnDemond.d.ts +4 -5
- package/dist/Renderer/copperRendererOnDemond.js +3 -3
- package/dist/Renderer/copperRendererOnDemond.js.map +1 -1
- package/dist/Scene/baseScene.d.ts +2 -2
- package/dist/Scene/baseScene.js +2 -2
- package/dist/Scene/baseScene.js.map +1 -1
- package/dist/Scene/commonSceneMethod.d.ts +1 -1
- package/dist/Scene/commonSceneMethod.js +1 -1
- package/dist/Scene/commonSceneMethod.js.map +1 -1
- package/dist/Scene/copperMScene.d.ts +2 -2
- package/dist/Scene/copperMScene.js +2 -2
- package/dist/Scene/copperMScene.js.map +1 -1
- package/dist/Scene/copperScene.d.ts +2 -2
- package/dist/Scene/copperScene.js +2 -2
- package/dist/Scene/copperScene.js.map +1 -1
- package/dist/Scene/copperSceneOnDemond.d.ts +2 -2
- package/dist/Scene/copperSceneOnDemond.js +2 -2
- package/dist/Scene/copperSceneOnDemond.js.map +1 -1
- package/dist/Utils/add3DLabel.d.ts +2 -2
- package/dist/Utils/segmentation/CommToolsData.d.ts +71 -0
- package/dist/Utils/segmentation/CommToolsData.js +267 -0
- package/dist/Utils/segmentation/CommToolsData.js.map +1 -0
- package/dist/Utils/segmentation/DragOperator.d.ts +30 -0
- package/dist/Utils/segmentation/DragOperator.js +243 -0
- package/dist/Utils/segmentation/DragOperator.js.map +1 -0
- package/dist/Utils/segmentation/DrawToolCore.d.ts +78 -0
- package/dist/Utils/segmentation/DrawToolCore.js +1083 -0
- package/dist/Utils/segmentation/DrawToolCore.js.map +1 -0
- package/dist/Utils/segmentation/NrrdTools.d.ts +178 -0
- package/dist/Utils/segmentation/NrrdTools.js +965 -0
- package/dist/Utils/segmentation/NrrdTools.js.map +1 -0
- package/dist/Utils/segmentation/coreTools/archive.d.ts +1 -0
- package/dist/Utils/segmentation/coreTools/archive.js +23 -0
- package/dist/Utils/segmentation/coreTools/archive.js.map +1 -0
- package/dist/Utils/segmentation/coreTools/coreType.d.ts +206 -0
- package/dist/Utils/segmentation/coreTools/coreType.js +2 -0
- package/dist/Utils/segmentation/coreTools/coreType.js.map +1 -0
- package/dist/Utils/segmentation/coreTools/divControlTools.d.ts +19 -0
- package/dist/Utils/segmentation/coreTools/divControlTools.js +48 -0
- package/dist/Utils/segmentation/coreTools/divControlTools.js.map +1 -0
- package/dist/Utils/segmentation/coreTools/gui.d.ts +123 -0
- package/dist/Utils/segmentation/coreTools/gui.js +306 -0
- package/dist/Utils/segmentation/coreTools/gui.js.map +1 -0
- package/dist/Utils/utils.d.ts +1 -1
- package/dist/Utils/utils.js +27 -12
- package/dist/Utils/utils.js.map +1 -1
- package/dist/Utils/workers/reformatSaveDataWorker.d.ts +3 -3
- package/dist/Utils/workers/reformatSaveDataWorker.js.map +1 -1
- package/dist/bundle.esm.js +2578 -2230
- package/dist/bundle.umd.js +2579 -2230
- package/dist/css/style.css +2 -18
- package/dist/index.d.ts +13 -11
- package/dist/index.js +11 -10
- package/dist/index.js.map +1 -1
- package/dist/types/Loader/copperNrrdLoader.d.ts +1 -1
- package/dist/types/Renderer/baseRenderer.d.ts +2 -2
- package/dist/types/Renderer/copperMSceneRenderer.d.ts +2 -2
- package/dist/types/Renderer/copperRenderer.d.ts +4 -4
- package/dist/types/Renderer/copperRendererOnDemond.d.ts +4 -5
- package/dist/types/Scene/baseScene.d.ts +2 -2
- package/dist/types/Scene/commonSceneMethod.d.ts +1 -1
- package/dist/types/Scene/copperMScene.d.ts +2 -2
- package/dist/types/Scene/copperScene.d.ts +2 -2
- package/dist/types/Scene/copperSceneOnDemond.d.ts +2 -2
- package/dist/types/Utils/add3DLabel.d.ts +2 -2
- package/dist/types/Utils/segmentation/CommToolsData.d.ts +71 -0
- package/dist/types/Utils/segmentation/DragOperator.d.ts +30 -0
- package/dist/types/Utils/segmentation/DrawToolCore.d.ts +78 -0
- package/dist/types/Utils/segmentation/NrrdTools.d.ts +178 -0
- package/dist/types/Utils/segmentation/coreTools/archive.d.ts +1 -0
- package/dist/types/Utils/segmentation/coreTools/coreType.d.ts +206 -0
- package/dist/types/Utils/segmentation/coreTools/divControlTools.d.ts +19 -0
- package/dist/types/Utils/segmentation/coreTools/gui.d.ts +123 -0
- package/dist/types/Utils/utils.d.ts +1 -1
- package/dist/types/Utils/workers/reformatSaveDataWorker.d.ts +3 -3
- package/dist/types/index.d.ts +13 -11
- package/dist/types/types/types.d.ts +4 -38
- package/dist/types/types.d.ts +4 -38
- package/package.json +1 -1
- package/dist/Utils/nrrd_tool.d.ts +0 -269
- package/dist/Utils/nrrd_tool.js +0 -2480
- package/dist/Utils/nrrd_tool.js.map +0 -1
- package/dist/types/Utils/nrrd_tool.d.ts +0 -269
package/dist/css/style.css
CHANGED
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
html,
|
|
2
2
|
body {
|
|
3
3
|
margin: 0;
|
|
4
|
-
/*background-color: black;*/
|
|
5
|
-
/*z-index: -999;*/
|
|
6
4
|
}
|
|
7
5
|
|
|
8
6
|
.copper3D_canvas {
|
|
@@ -20,16 +18,7 @@ body {
|
|
|
20
18
|
justify-content: center;
|
|
21
19
|
align-items: center;
|
|
22
20
|
}
|
|
23
|
-
|
|
24
|
-
position: absolute;
|
|
25
|
-
top: 0;
|
|
26
|
-
left: 50%;
|
|
27
|
-
width: 2px;
|
|
28
|
-
height: 100%;
|
|
29
|
-
background-color: #555;
|
|
30
|
-
cursor: col-resize;
|
|
31
|
-
z-index: 99;
|
|
32
|
-
}
|
|
21
|
+
|
|
33
22
|
.copper3D_scene_div {
|
|
34
23
|
border: 1px solid grey;
|
|
35
24
|
position: relative;
|
|
@@ -63,7 +52,6 @@ body {
|
|
|
63
52
|
z-index: 1000;
|
|
64
53
|
}
|
|
65
54
|
|
|
66
|
-
/* copper3D_drawingCanvasContainer */
|
|
67
55
|
.copper3D_display_area {
|
|
68
56
|
position: relative;
|
|
69
57
|
display: flex;
|
|
@@ -77,13 +65,12 @@ body {
|
|
|
77
65
|
display: flex;
|
|
78
66
|
justify-content: center;
|
|
79
67
|
align-items: center;
|
|
80
|
-
|
|
68
|
+
|
|
81
69
|
max-width: 80vw;
|
|
82
70
|
max-height: 80vh;
|
|
83
71
|
overflow: hidden;
|
|
84
72
|
}
|
|
85
73
|
|
|
86
|
-
/* loading */
|
|
87
74
|
.copper3D_flex-center {
|
|
88
75
|
display: flex;
|
|
89
76
|
justify-content: space-between;
|
|
@@ -92,8 +79,6 @@ body {
|
|
|
92
79
|
flex-direction: column;
|
|
93
80
|
height: 100px;
|
|
94
81
|
position: absolute;
|
|
95
|
-
/* left: 45%;
|
|
96
|
-
top: 45%; */
|
|
97
82
|
}
|
|
98
83
|
.copper3D_three-balls-bounce {
|
|
99
84
|
position: relative;
|
|
@@ -165,4 +150,3 @@ body {
|
|
|
165
150
|
opacity: 0.4;
|
|
166
151
|
}
|
|
167
152
|
}
|
|
168
|
-
/* loading end */
|
package/dist/index.d.ts
CHANGED
|
@@ -1,22 +1,24 @@
|
|
|
1
|
-
import copperRenderer from "./Renderer/copperRenderer";
|
|
1
|
+
import { copperRenderer } from "./Renderer/copperRenderer";
|
|
2
2
|
import { setHDRFilePath } from "./lib/environment/index";
|
|
3
|
-
import copperScene from "./Scene/copperScene";
|
|
3
|
+
import { copperScene } from "./Scene/copperScene";
|
|
4
4
|
import { CameraViewPoint } from "./Controls/copperControls";
|
|
5
5
|
import { addLabelToScene, positionType, screenPosType, convert3DPostoScreenPos, convertScreenPosto3DPos } from "./Utils/add3DLabel";
|
|
6
6
|
import { addBoxHelper, optsType } from "./Loader/copperNrrdLoader";
|
|
7
7
|
import { fullScreenListenner, loading, throttle } from "./Utils/utils";
|
|
8
|
-
import copperRendererOnDemond from "./Renderer/copperRendererOnDemond";
|
|
9
|
-
import copperSceneOnDemond from "./Scene/copperSceneOnDemond";
|
|
10
|
-
import copperMSceneRenderer from "./Renderer/copperMSceneRenderer";
|
|
11
|
-
import copperMScene from "./Scene/copperMScene";
|
|
8
|
+
import { copperRendererOnDemond } from "./Renderer/copperRendererOnDemond";
|
|
9
|
+
import { copperSceneOnDemond } from "./Scene/copperSceneOnDemond";
|
|
10
|
+
import { copperMSceneRenderer } from "./Renderer/copperMSceneRenderer";
|
|
11
|
+
import { copperMScene } from "./Scene/copperMScene";
|
|
12
12
|
import { createTexture2D_NRRD } from "./Utils/texture2d";
|
|
13
13
|
import { configKiwriousHeart } from "./Utils/kiwrious/configKiwrious";
|
|
14
14
|
import kiwrious from "./Utils/kiwrious/configKiwrious";
|
|
15
|
-
import {
|
|
15
|
+
import { NrrdTools } from "./Utils/segmentation/NrrdTools";
|
|
16
16
|
import { Copper3dTrackballControls } from "./Controls/Copper3dTrackballControls";
|
|
17
17
|
import { MeshNodeTool } from "./Utils/MeshNodeTool";
|
|
18
|
-
import {
|
|
18
|
+
import { removeGuiFolderChilden } from "./Utils/segmentation/coreTools/gui";
|
|
19
|
+
import { nrrdMeshesType, nrrdSliceType, SensorDecodedValue_kiwrious, SensorReadResult_kiwrious, HeartRateResult_kiwrious, loadingBarType, exportPaintImageType, IOptVTKLoader } from "./types/types";
|
|
20
|
+
import { IPaintImage } from "./Utils/segmentation/coreTools/coreType";
|
|
19
21
|
import "./css/style.css";
|
|
20
|
-
export declare const REVISION = "
|
|
21
|
-
export { copperRenderer, copperRendererOnDemond, copperMSceneRenderer, setHDRFilePath, addLabelToScene, convert3DPostoScreenPos, convertScreenPosto3DPos, addBoxHelper, fullScreenListenner, configKiwriousHeart, copperScene, copperSceneOnDemond, copperMScene, CameraViewPoint, kiwrious,
|
|
22
|
-
export type { positionType, screenPosType, optsType, nrrdMeshesType, nrrdSliceType, SensorDecodedValue_kiwrious, SensorReadResult_kiwrious, HeartRateResult_kiwrious, loadingBarType,
|
|
22
|
+
export declare const REVISION = "v2.0.1";
|
|
23
|
+
export { copperRenderer, copperRendererOnDemond, copperMSceneRenderer, setHDRFilePath, addLabelToScene, convert3DPostoScreenPos, convertScreenPosto3DPos, addBoxHelper, fullScreenListenner, configKiwriousHeart, copperScene, copperSceneOnDemond, copperMScene, CameraViewPoint, kiwrious, NrrdTools, loading, Copper3dTrackballControls, createTexture2D_NRRD, MeshNodeTool, throttle, removeGuiFolderChilden, };
|
|
24
|
+
export type { positionType, screenPosType, optsType, nrrdMeshesType, nrrdSliceType, SensorDecodedValue_kiwrious, SensorReadResult_kiwrious, HeartRateResult_kiwrious, loadingBarType, IPaintImage, exportPaintImageType, IOptVTKLoader, };
|
package/dist/index.js
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
1
|
// import * as kiwrious from "copper3d_plugin_heart_k";
|
|
2
|
-
import copperRenderer from "./Renderer/copperRenderer";
|
|
2
|
+
import { copperRenderer } from "./Renderer/copperRenderer";
|
|
3
3
|
import { setHDRFilePath } from "./lib/environment/index";
|
|
4
|
-
import copperScene from "./Scene/copperScene";
|
|
4
|
+
import { copperScene } from "./Scene/copperScene";
|
|
5
5
|
import { CameraViewPoint } from "./Controls/copperControls";
|
|
6
6
|
import { addLabelToScene, convert3DPostoScreenPos, convertScreenPosto3DPos, } from "./Utils/add3DLabel";
|
|
7
7
|
import { addBoxHelper } from "./Loader/copperNrrdLoader";
|
|
8
8
|
import { fullScreenListenner, loading, throttle } from "./Utils/utils";
|
|
9
|
-
import copperRendererOnDemond from "./Renderer/copperRendererOnDemond";
|
|
10
|
-
import copperSceneOnDemond from "./Scene/copperSceneOnDemond";
|
|
11
|
-
import copperMSceneRenderer from "./Renderer/copperMSceneRenderer";
|
|
12
|
-
import copperMScene from "./Scene/copperMScene";
|
|
9
|
+
import { copperRendererOnDemond } from "./Renderer/copperRendererOnDemond";
|
|
10
|
+
import { copperSceneOnDemond } from "./Scene/copperSceneOnDemond";
|
|
11
|
+
import { copperMSceneRenderer } from "./Renderer/copperMSceneRenderer";
|
|
12
|
+
import { copperMScene } from "./Scene/copperMScene";
|
|
13
13
|
import { createTexture2D_NRRD } from "./Utils/texture2d";
|
|
14
14
|
import { configKiwriousHeart } from "./Utils/kiwrious/configKiwrious";
|
|
15
15
|
import kiwrious from "./Utils/kiwrious/configKiwrious";
|
|
16
|
-
import {
|
|
16
|
+
import { NrrdTools } from "./Utils/segmentation/NrrdTools";
|
|
17
17
|
import { Copper3dTrackballControls } from "./Controls/Copper3dTrackballControls";
|
|
18
18
|
import { MeshNodeTool } from "./Utils/MeshNodeTool";
|
|
19
|
+
import { removeGuiFolderChilden } from "./Utils/segmentation/coreTools/gui";
|
|
19
20
|
import "./css/style.css";
|
|
20
|
-
export const REVISION = "
|
|
21
|
-
console.log("%cCopper3D Visualisation %cBeta:
|
|
22
|
-
export { copperRenderer, copperRendererOnDemond, copperMSceneRenderer, setHDRFilePath, addLabelToScene, convert3DPostoScreenPos, convertScreenPosto3DPos, addBoxHelper, fullScreenListenner, configKiwriousHeart, copperScene, copperSceneOnDemond, copperMScene, CameraViewPoint, kiwrious,
|
|
21
|
+
export const REVISION = "v2.0.1";
|
|
22
|
+
console.log("%cCopper3D Visualisation %cBeta:v2.0.1", "padding: 3px;color:white; background:#023047", "padding: 3px;color:white; background:#f50a25");
|
|
23
|
+
export { copperRenderer, copperRendererOnDemond, copperMSceneRenderer, setHDRFilePath, addLabelToScene, convert3DPostoScreenPos, convertScreenPosto3DPos, addBoxHelper, fullScreenListenner, configKiwriousHeart, copperScene, copperSceneOnDemond, copperMScene, CameraViewPoint, kiwrious, NrrdTools, loading, Copper3dTrackballControls, createTexture2D_NRRD, MeshNodeTool, throttle, removeGuiFolderChilden, };
|
|
23
24
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,uDAAuD;AAEvD,OAAO,cAAc,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,uDAAuD;AAEvD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzD,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EACL,eAAe,EAGf,uBAAuB,EACvB,uBAAuB,GACxB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,YAAY,EAAY,MAAM,2BAA2B,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAC;AAC3E,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AAClE,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEpD,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAEzD,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AACtE,OAAO,QAAQ,MAAM,iCAAiC,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAE3D,OAAO,EAAE,yBAAyB,EAAE,MAAM,sCAAsC,CAAC;AAEjF,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAe5E,OAAO,iBAAiB,CAAC;AAEzB,MAAM,CAAC,MAAM,QAAQ,GAAG,QAAQ,CAAC;AAEjC,OAAO,CAAC,GAAG,CACT,wCAAwC,EACxC,8CAA8C,EAC9C,8CAA8C,CAC/C,CAAC;AAEF,OAAO,EACL,cAAc,EACd,sBAAsB,EACtB,oBAAoB,EACpB,cAAc,EACd,eAAe,EACf,uBAAuB,EACvB,uBAAuB,EACvB,YAAY,EACZ,mBAAmB,EACnB,mBAAmB,EACnB,WAAW,EACX,mBAAmB,EACnB,YAAY,EACZ,eAAe,EACf,QAAQ,EACR,SAAS,EACT,OAAO,EACP,yBAAyB,EACzB,oBAAoB,EACpB,YAAY,EACZ,QAAQ,EACR,sBAAsB,GACvB,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as THREE from "three";
|
|
2
|
-
import copperScene from "../Scene/copperScene";
|
|
2
|
+
import { copperScene } from "../Scene/copperScene";
|
|
3
3
|
import { GUI } from "dat.gui";
|
|
4
4
|
import { nrrdMeshesType, nrrdSliceType, loadingBarType } from "../types/types";
|
|
5
5
|
import { Copper3dTrackballControls } from "../Controls/Copper3dTrackballControls";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/// <reference types="stats.js" />
|
|
2
2
|
import * as THREE from "three";
|
|
3
|
-
import baseScene from "../Scene/baseScene";
|
|
3
|
+
import { baseScene } from "../Scene/baseScene";
|
|
4
4
|
import { customMeshType } from "../lib/three-vignette";
|
|
5
5
|
import Stats from "three/examples/jsm/libs/stats.module";
|
|
6
6
|
import { GUI } from "dat.gui";
|
|
7
7
|
import { ICopperRenderOpt } from "../types/types";
|
|
8
|
-
export
|
|
8
|
+
export declare class baseRenderer {
|
|
9
9
|
container: HTMLDivElement;
|
|
10
10
|
renderer: THREE.WebGLRenderer;
|
|
11
11
|
gui: GUI | null;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as THREE from "three";
|
|
2
|
-
import copperMScene from "../Scene/copperMScene";
|
|
2
|
+
import { copperMScene } from "../Scene/copperMScene";
|
|
3
3
|
import { positionType } from "../types/types";
|
|
4
|
-
export
|
|
4
|
+
export declare class copperMSceneRenderer {
|
|
5
5
|
numberOfScene: number;
|
|
6
6
|
container: HTMLDivElement;
|
|
7
7
|
elems: Array<HTMLDivElement>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import baseRenderer from "./baseRenderer";
|
|
2
|
-
import copperScene from "../Scene/copperScene";
|
|
1
|
+
import { baseRenderer } from "./baseRenderer";
|
|
2
|
+
import { copperScene } from "../Scene/copperScene";
|
|
3
3
|
import { ICopperRenderOpt } from "../types/types";
|
|
4
|
-
export
|
|
4
|
+
export declare class copperRenderer extends baseRenderer {
|
|
5
5
|
private sceneMap;
|
|
6
6
|
private fps;
|
|
7
7
|
private renderClock;
|
|
@@ -9,7 +9,7 @@ export default class copperRenderer extends baseRenderer {
|
|
|
9
9
|
private interval;
|
|
10
10
|
preRenderCallbackFunctions: Array<Function>;
|
|
11
11
|
constructor(container: HTMLDivElement, options?: ICopperRenderOpt);
|
|
12
|
-
getSceneByName(name: string): copperScene | import("../Scene/baseScene").
|
|
12
|
+
getSceneByName(name: string): copperScene | import("../Scene/baseScene").baseScene | import("../index").copperMScene;
|
|
13
13
|
setFPS(fps: number): void;
|
|
14
14
|
setCurrentScene(sceneIn: copperScene): void;
|
|
15
15
|
createScene(name: string): copperScene | undefined;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import baseRenderer from "./baseRenderer";
|
|
2
|
-
import copperScene from "../Scene/copperScene";
|
|
1
|
+
import { baseRenderer } from "./baseRenderer";
|
|
3
2
|
import { ICopperRenderOpt } from "../types/types";
|
|
4
|
-
import copperSceneOnDemond from "../Scene/copperSceneOnDemond";
|
|
5
|
-
export
|
|
3
|
+
import { copperSceneOnDemond } from "../Scene/copperSceneOnDemond";
|
|
4
|
+
export declare class copperRendererOnDemond extends baseRenderer {
|
|
6
5
|
private sceneMap;
|
|
7
6
|
constructor(container: HTMLDivElement, options?: ICopperRenderOpt);
|
|
8
|
-
getSceneByName(name: string): copperScene | import("../Scene/baseScene").
|
|
7
|
+
getSceneByName(name: string): import("../index").copperScene | import("../Scene/baseScene").baseScene | import("../index").copperMScene;
|
|
9
8
|
setCurrentScene(sceneIn: copperSceneOnDemond): void;
|
|
10
9
|
createScene(name: string): copperSceneOnDemond | undefined;
|
|
11
10
|
animate: () => void;
|
|
@@ -2,8 +2,8 @@ import * as THREE from "three";
|
|
|
2
2
|
import { Controls, CameraViewPoint } from "../Controls/copperControls";
|
|
3
3
|
import { customMeshType } from "../lib/three-vignette";
|
|
4
4
|
import { baseStateType, ICopperSceneOpts } from "../types/types";
|
|
5
|
-
import commonScene from "./commonSceneMethod";
|
|
6
|
-
export
|
|
5
|
+
import { commonScene } from "./commonSceneMethod";
|
|
6
|
+
export declare class baseScene extends commonScene {
|
|
7
7
|
renderer: THREE.WebGLRenderer;
|
|
8
8
|
sceneName: string;
|
|
9
9
|
vignette: customMeshType | undefined;
|
|
@@ -6,7 +6,7 @@ import { Controls } from "../Controls/copperControls";
|
|
|
6
6
|
import { Copper3dTrackballControls } from "../Controls/Copper3dTrackballControls";
|
|
7
7
|
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls";
|
|
8
8
|
import { TrackballControls } from "three/examples/jsm/controls/TrackballControls";
|
|
9
|
-
export
|
|
9
|
+
export declare class commonScene {
|
|
10
10
|
container: HTMLDivElement;
|
|
11
11
|
scene: THREE.Scene;
|
|
12
12
|
camera: THREE.PerspectiveCamera | THREE.OrthographicCamera;
|
|
@@ -3,8 +3,8 @@ import { GUI } from "dat.gui";
|
|
|
3
3
|
import { Controls, CameraViewPoint } from "../Controls/copperControls";
|
|
4
4
|
import { customMeshType } from "../lib/three-vignette";
|
|
5
5
|
import { positionType, nrrdSliceType } from "../types/types";
|
|
6
|
-
import commonScene from "./commonSceneMethod";
|
|
7
|
-
export
|
|
6
|
+
import { commonScene } from "./commonSceneMethod";
|
|
7
|
+
export declare class copperMScene extends commonScene {
|
|
8
8
|
gui: GUI;
|
|
9
9
|
container: HTMLDivElement;
|
|
10
10
|
renderer: THREE.WebGLRenderer;
|
|
@@ -2,11 +2,11 @@ import * as THREE from "three";
|
|
|
2
2
|
import { Copper3dTrackballControls } from "../Controls/Copper3dTrackballControls";
|
|
3
3
|
import { CameraViewPoint } from "../Controls/copperControls";
|
|
4
4
|
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls";
|
|
5
|
-
import baseScene from "./baseScene";
|
|
5
|
+
import { baseScene } from "./baseScene";
|
|
6
6
|
import { vtkModels } from "../types/types";
|
|
7
7
|
import { TrackballControls } from "three/examples/jsm/controls/TrackballControls";
|
|
8
8
|
import { ICopperSceneOpts } from "../types/types";
|
|
9
|
-
export
|
|
9
|
+
export declare class copperScene extends baseScene {
|
|
10
10
|
clock: THREE.Clock;
|
|
11
11
|
controls: Copper3dTrackballControls | OrbitControls | TrackballControls;
|
|
12
12
|
private mixer;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as THREE from "three";
|
|
2
|
-
import baseScene from "./baseScene";
|
|
2
|
+
import { baseScene } from "./baseScene";
|
|
3
3
|
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls";
|
|
4
|
-
export
|
|
4
|
+
export declare class copperSceneOnDemond extends baseScene {
|
|
5
5
|
controls: OrbitControls;
|
|
6
6
|
renderRequested: boolean | undefined;
|
|
7
7
|
isResize: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import baseScene from "../Scene/baseScene";
|
|
2
|
-
import copperMScene from "../Scene/copperMScene";
|
|
1
|
+
import { baseScene } from "../Scene/baseScene";
|
|
2
|
+
import { copperMScene } from "../Scene/copperMScene";
|
|
3
3
|
import * as THREE from "three";
|
|
4
4
|
export declare function addLabelToScene(scene: baseScene | copperMScene, text: string, x: number, y: number, z: number, scaling: number, option?: {
|
|
5
5
|
font_size: string;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { IProtected, IGUIStates, INrrdStates, ICursorPage, IPaintImages, IConvertObjType } from "./coreTools/coreType";
|
|
2
|
+
export declare class CommToolsData {
|
|
3
|
+
baseCanvasesSize: number;
|
|
4
|
+
nrrd_states: INrrdStates;
|
|
5
|
+
cursorPage: ICursorPage;
|
|
6
|
+
gui_states: IGUIStates;
|
|
7
|
+
protectedData: IProtected;
|
|
8
|
+
constructor(container: HTMLElement, mainAreaContainer: HTMLElement);
|
|
9
|
+
private generateCanvases;
|
|
10
|
+
/**
|
|
11
|
+
* Rewrite this {clearPaint} function under DrawToolCore
|
|
12
|
+
*/
|
|
13
|
+
clearPaint(): void;
|
|
14
|
+
/**
|
|
15
|
+
* Rewrite this {undoLastPainting} function under DrawToolCore
|
|
16
|
+
*/
|
|
17
|
+
undoLastPainting(): void;
|
|
18
|
+
/**
|
|
19
|
+
* Rewrite this {clearStoreImages} function under NrrdTools
|
|
20
|
+
*/
|
|
21
|
+
clearStoreImages(): void;
|
|
22
|
+
/**
|
|
23
|
+
* Rewrite this {resizePaintArea} function under NrrdTools
|
|
24
|
+
*/
|
|
25
|
+
resizePaintArea(factor: number): void;
|
|
26
|
+
/**
|
|
27
|
+
* Rewrite this {setIsDrawFalse} function under NrrdTools
|
|
28
|
+
*/
|
|
29
|
+
setIsDrawFalse(target: number): void;
|
|
30
|
+
/**
|
|
31
|
+
* Rewrite this {updateOriginAndChangedWH} function under NrrdTools
|
|
32
|
+
*/
|
|
33
|
+
updateOriginAndChangedWH(): void;
|
|
34
|
+
/**
|
|
35
|
+
* Rewrite this {flipDisplayImageByAxis} function under NrrdTools
|
|
36
|
+
*/
|
|
37
|
+
flipDisplayImageByAxis(): void;
|
|
38
|
+
/**
|
|
39
|
+
* Rewrite this {resetPaintAreaUIPosition} function under NrrdTools
|
|
40
|
+
*/
|
|
41
|
+
resetPaintAreaUIPosition(l?: number, t?: number): void;
|
|
42
|
+
/**
|
|
43
|
+
* Rewrite this {resetPaintAreaUIPosition} function under NrrdTools
|
|
44
|
+
*/
|
|
45
|
+
setEmptyCanvasSize(axis?: "x" | "y" | "z"): void;
|
|
46
|
+
/**
|
|
47
|
+
* Rewrite this {convertCursorPoint} function under NrrdTools
|
|
48
|
+
*/
|
|
49
|
+
convertCursorPoint(from: "x" | "y" | "z", to: "x" | "y" | "z", cursorNumX: number, cursorNumY: number, currentSliceIndex: number): IConvertObjType | undefined;
|
|
50
|
+
/**
|
|
51
|
+
* Rewrite this {resetLayerCanvas} function under NrrdTools
|
|
52
|
+
*/
|
|
53
|
+
resetLayerCanvas(): void;
|
|
54
|
+
/**
|
|
55
|
+
* Rewrite this {setSyncsliceNum} function under NrrdTools
|
|
56
|
+
*/
|
|
57
|
+
setSyncsliceNum(): void;
|
|
58
|
+
/**
|
|
59
|
+
* Rewrite this {redrawDisplayCanvas} function under NrrdTools
|
|
60
|
+
*/
|
|
61
|
+
redrawDisplayCanvas(): void;
|
|
62
|
+
/**
|
|
63
|
+
* Get a painted mask image (IPaintImage) based on current axis and input slice index.
|
|
64
|
+
*
|
|
65
|
+
* @param axis "x" | "y" | "z"
|
|
66
|
+
* @param sliceIndex number
|
|
67
|
+
* @param paintedImages IPaintImages, All painted mask images.
|
|
68
|
+
* @returns
|
|
69
|
+
*/
|
|
70
|
+
filterDrawedImage(axis: "x" | "y" | "z", sliceIndex: number, paintedImages: IPaintImages): import("./coreTools/coreType").IPaintImage;
|
|
71
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { IDragOpts, IDrawingEvents, IProtected, IGUIStates, INrrdStates, IPaintImage, IPaintImages } from "./coreTools/coreType";
|
|
2
|
+
export declare class DragOperator {
|
|
3
|
+
container: HTMLElement;
|
|
4
|
+
private dragPrameters;
|
|
5
|
+
private drawingPrameters;
|
|
6
|
+
private sensitiveArray;
|
|
7
|
+
private showDragNumberDiv;
|
|
8
|
+
private nrrd_states;
|
|
9
|
+
private gui_states;
|
|
10
|
+
private protectedData;
|
|
11
|
+
private dragEffectCanvases;
|
|
12
|
+
private setSyncsliceNum;
|
|
13
|
+
private setIsDrawFalse;
|
|
14
|
+
private flipDisplayImageByAxis;
|
|
15
|
+
private setEmptyCanvasSize;
|
|
16
|
+
private filterDrawedImage;
|
|
17
|
+
constructor(container: HTMLElement, nrrd_sates: INrrdStates, gui_states: IGUIStates, protectedData: IProtected, drawingPrameters: IDrawingEvents, setSyncsliceNum: () => void, setIsDrawFalse: (target: number) => void, flipDisplayImageByAxis: () => void, setEmptyCanvasSize: (axis?: "x" | "y" | "z") => void, filterDrawedImage: (axis: "x" | "y" | "z", sliceIndex: number, paintedImages: IPaintImages) => IPaintImage);
|
|
18
|
+
private init;
|
|
19
|
+
setShowDragNumberDiv(sliceIndexContainer: HTMLDivElement): void;
|
|
20
|
+
drag(opts?: IDragOpts): void;
|
|
21
|
+
updateIndex(move: number): void;
|
|
22
|
+
private drawDragSlice;
|
|
23
|
+
private drawMaskToLabelCtx;
|
|
24
|
+
private cleanCanvases;
|
|
25
|
+
updateShowNumDiv(contrastNum: number): void;
|
|
26
|
+
updateCurrentContrastSlice(): any;
|
|
27
|
+
configDragMode: () => void;
|
|
28
|
+
removeDragMode: () => void;
|
|
29
|
+
updateMainSlice(mainPreSlices: any): void;
|
|
30
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { IDrawingEvents, IDrawOpts, IUndoType } from "./coreTools/coreType";
|
|
2
|
+
import { CommToolsData } from "./CommToolsData";
|
|
3
|
+
export declare class DrawToolCore extends CommToolsData {
|
|
4
|
+
container: HTMLElement;
|
|
5
|
+
mainAreaContainer: HTMLDivElement;
|
|
6
|
+
drawingPrameters: IDrawingEvents;
|
|
7
|
+
eraserUrls: string[];
|
|
8
|
+
pencilUrls: string[];
|
|
9
|
+
undoArray: Array<IUndoType>;
|
|
10
|
+
start: () => void;
|
|
11
|
+
constructor(container: HTMLElement);
|
|
12
|
+
private initDrawToolCore;
|
|
13
|
+
setEraserUrls(urls: string[]): void;
|
|
14
|
+
setPencilIconUrls(urls: string[]): void;
|
|
15
|
+
private setCurrentLayer;
|
|
16
|
+
draw(opts?: IDrawOpts): void;
|
|
17
|
+
private paintOnCanvas;
|
|
18
|
+
/*************************************May consider to move outside *******************************************/
|
|
19
|
+
private drawLine;
|
|
20
|
+
private drawLinesOnLayer;
|
|
21
|
+
private paintOnCanvasLayer;
|
|
22
|
+
private initAllCanvas;
|
|
23
|
+
private useEraser;
|
|
24
|
+
private configMouseZoomWheel;
|
|
25
|
+
private enableCrosshair;
|
|
26
|
+
private drawImageOnEmptyImage;
|
|
27
|
+
/****************************Sphere functions****************************************************/
|
|
28
|
+
private storeSphereImages;
|
|
29
|
+
private drawSphereOnEachViews;
|
|
30
|
+
private drawSphereCore;
|
|
31
|
+
private setSphereCanvasSize;
|
|
32
|
+
private configMouseSphereWheel;
|
|
33
|
+
drawSphere(mouseX: number, mouseY: number, radius: number): void;
|
|
34
|
+
private setUpSphereOrigins;
|
|
35
|
+
/****************************label div controls****************************************************/
|
|
36
|
+
private getRestLabel;
|
|
37
|
+
/**************************** Undo clear functions****************************************************/
|
|
38
|
+
private getCurrentUndo;
|
|
39
|
+
/**
|
|
40
|
+
* Clear mask on current slice canvas
|
|
41
|
+
*/
|
|
42
|
+
clearPaint(): void;
|
|
43
|
+
undoLastPainting(): void;
|
|
44
|
+
/****************************Store images****************************************************/
|
|
45
|
+
private storeImageToAxis;
|
|
46
|
+
storeAllImages(index: number, label: string): void;
|
|
47
|
+
private storeImageToLabel;
|
|
48
|
+
storeEachLayerImage(index: number, label: string): void;
|
|
49
|
+
private sliceArrayH;
|
|
50
|
+
private sliceArrayV;
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @param paintImageArray : the target view slice's marked images array
|
|
54
|
+
* @param length : the target view slice's dimention (total slice index num)
|
|
55
|
+
* @param ratio : the target slice image's width/height ratio of its dimention length
|
|
56
|
+
* @param markedArr : current painted image's vertical 2d Array
|
|
57
|
+
* @param targetWidth : the target image width
|
|
58
|
+
* @param convertIndex : Mapping current image's index to target slice image's width/height pixel start point
|
|
59
|
+
*/
|
|
60
|
+
private replaceVerticalColPixels;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @param paintImageArray : the target view slice's marked images array
|
|
64
|
+
* @param length : the target view slice's dimention (total slice index num)
|
|
65
|
+
* @param ratio : the target slice image's width/height ratio of its dimention length
|
|
66
|
+
* @param markedArr : current painted image's horizontal 2d Array
|
|
67
|
+
* @param targetWidth : the target image width
|
|
68
|
+
* @param convertIndex : Mapping current image's index to target slice image's width/height pixel start point
|
|
69
|
+
*/
|
|
70
|
+
private replaceHorizontalRowPixels;
|
|
71
|
+
/****************************** Utils for store image and itksnap core **************************************/
|
|
72
|
+
private checkSharedPlaceSlice;
|
|
73
|
+
private replaceArray;
|
|
74
|
+
private findSliceInSharedPlace;
|
|
75
|
+
/******************************** Utils gui related functions ***************************************/
|
|
76
|
+
updateSlicesContrast(value: number, flag: string): void;
|
|
77
|
+
repraintCurrentContrastSlice(): void;
|
|
78
|
+
}
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
import { nrrdSliceType, storeExportPaintImageType, loadingBarType } from "../../types/types";
|
|
2
|
+
import { GUI } from "dat.gui";
|
|
3
|
+
import { IStoredPaintImages, IMaskData, IDragOpts } from "./coreTools/coreType";
|
|
4
|
+
import { DragOperator } from "./DragOperator";
|
|
5
|
+
import { DrawToolCore } from "./DrawToolCore";
|
|
6
|
+
export declare class NrrdTools extends DrawToolCore {
|
|
7
|
+
container: HTMLDivElement;
|
|
8
|
+
dragOperator: DragOperator;
|
|
9
|
+
storedPaintImages: IStoredPaintImages | undefined;
|
|
10
|
+
private paintedImage;
|
|
11
|
+
private initState;
|
|
12
|
+
private preTimer;
|
|
13
|
+
private guiParameterSettings;
|
|
14
|
+
constructor(container: HTMLDivElement);
|
|
15
|
+
/**
|
|
16
|
+
* core function for drag slices
|
|
17
|
+
* @param opts
|
|
18
|
+
*/
|
|
19
|
+
drag(opts?: IDragOpts): void;
|
|
20
|
+
/**
|
|
21
|
+
* Set the Draw Display Canvas base size
|
|
22
|
+
* @param size number
|
|
23
|
+
*/
|
|
24
|
+
setBaseDrawDisplayCanvasesSize(size: number): void;
|
|
25
|
+
setDisplaySliceIndexPanel(panel: HTMLDivElement): void;
|
|
26
|
+
/**
|
|
27
|
+
* Set up GUI for drawing panel
|
|
28
|
+
* @param gui GUI
|
|
29
|
+
*/
|
|
30
|
+
setupGUI(gui: GUI): void;
|
|
31
|
+
getGuiSettings(): {
|
|
32
|
+
guiState: import("./coreTools/coreType").IGUIStates;
|
|
33
|
+
guiSetting: any;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* A initialise function for nrrd_tools
|
|
37
|
+
*/
|
|
38
|
+
private init;
|
|
39
|
+
/**
|
|
40
|
+
*
|
|
41
|
+
* entry function
|
|
42
|
+
* * {
|
|
43
|
+
* x:slice,
|
|
44
|
+
* y:slice,
|
|
45
|
+
* z:slice
|
|
46
|
+
* }
|
|
47
|
+
*
|
|
48
|
+
* @param allSlices - all nrrd contrast slices
|
|
49
|
+
|
|
50
|
+
*/
|
|
51
|
+
setAllSlices(allSlices: Array<nrrdSliceType>): void;
|
|
52
|
+
private loadingMaskByLabel;
|
|
53
|
+
setMasksData(masksData: storeExportPaintImageType, loadingBar?: loadingBarType): void;
|
|
54
|
+
private setShowInMainArea;
|
|
55
|
+
getCurrentImageDimension(): number[];
|
|
56
|
+
getVoxelSpacing(): number[];
|
|
57
|
+
getSpaceOrigin(): number[];
|
|
58
|
+
getMaskData(): IMaskData;
|
|
59
|
+
private getSharedPlace;
|
|
60
|
+
/**
|
|
61
|
+
* init all painted images for store images
|
|
62
|
+
* @param dimensions
|
|
63
|
+
*/
|
|
64
|
+
private initPaintImages;
|
|
65
|
+
private createEmptyPaintImage;
|
|
66
|
+
/**
|
|
67
|
+
* We generate the MRI slice from threejs based on mm, but when we display it is based on pixel size/distance.
|
|
68
|
+
* So, the index munber on each axis (sagittal, axial, coronal) is the slice's depth in mm distance. And the width and height displayed on screen is the slice's width and height in pixel distance.
|
|
69
|
+
*
|
|
70
|
+
* When we switch into different axis' views, we need to convert current view's the depth to the pixel distance in other views width or height, and convert the current view's width or height from pixel distance to mm distance as other views' depth (slice index) in general.
|
|
71
|
+
*
|
|
72
|
+
* Then as for the crosshair (Cursor Inspector), we also need to convert the cursor point (x, y, z) to other views' (x, y, z).
|
|
73
|
+
*
|
|
74
|
+
* @param from "x" | "y" | "z", current view axis, "x: sagittle, y: coronal, z: axial".
|
|
75
|
+
* @param to "x" | "y" | "z", target view axis (where you want jump to), "x: sagittle, y: coronal, z: axial".
|
|
76
|
+
* @param cursorNumX number, cursor point x on current axis's slice. (pixel distance)
|
|
77
|
+
* @param cursorNumY number, cursor point y on current axis's slice. (pixel distance)
|
|
78
|
+
* @param currentSliceIndex number, current axis's slice's index/depth. (mm distance)
|
|
79
|
+
* @returns
|
|
80
|
+
*/
|
|
81
|
+
convertCursorPoint(from: "x" | "y" | "z", to: "x" | "y" | "z", cursorNumX: number, cursorNumY: number, currentSliceIndex: number): {
|
|
82
|
+
currentIndex: number;
|
|
83
|
+
oldIndex: number;
|
|
84
|
+
convertCursorNumX: number;
|
|
85
|
+
convertCursorNumY: number;
|
|
86
|
+
} | undefined;
|
|
87
|
+
/**
|
|
88
|
+
* Switch all contrast slices' orientation
|
|
89
|
+
* @param {string} aixs:"x" | "y" | "z"
|
|
90
|
+
* */
|
|
91
|
+
setSliceOrientation(axisTo: "x" | "y" | "z"): void;
|
|
92
|
+
addSkip(index: number): void;
|
|
93
|
+
removeSkip(index: number): void;
|
|
94
|
+
clear(): void;
|
|
95
|
+
setSliceMoving(step: number): void;
|
|
96
|
+
setMainAreaSize(factor: number): void;
|
|
97
|
+
getContainer(): HTMLElement;
|
|
98
|
+
getDrawingCanvas(): HTMLCanvasElement;
|
|
99
|
+
getNrrdToolsSettings(): import("./coreTools/coreType").INrrdStates;
|
|
100
|
+
getMaxSliceNum(): number[];
|
|
101
|
+
getCurrentSlicesNumAndContrastNum(): {
|
|
102
|
+
currentIndex: number;
|
|
103
|
+
contrastIndex: number;
|
|
104
|
+
};
|
|
105
|
+
getCurrentSliceIndex(): number;
|
|
106
|
+
getIsShowContrastState(): boolean;
|
|
107
|
+
/**
|
|
108
|
+
* Give a delay time to finish the last drawing before upcoming interrupt opreations.
|
|
109
|
+
* Give a delay time number (ms) to disable the draw function,
|
|
110
|
+
* After your interrupt opeartion, you should enable the draw fucntion.
|
|
111
|
+
* @param target number
|
|
112
|
+
*/
|
|
113
|
+
setIsDrawFalse(target: number): void;
|
|
114
|
+
private setDisplaySlicesBaseOnAxis;
|
|
115
|
+
private loadDisplaySlicesArray;
|
|
116
|
+
switchAllSlicesArrayData(allSlices: Array<nrrdSliceType>): void;
|
|
117
|
+
private resetDisplaySlicesStatus;
|
|
118
|
+
private setupConfigs;
|
|
119
|
+
private setMainPreSlice;
|
|
120
|
+
private setOriginCanvasAndPre;
|
|
121
|
+
private afterLoadSlice;
|
|
122
|
+
private updateMaxIndex;
|
|
123
|
+
/**
|
|
124
|
+
* Update the original canvas size, allow set to threejs load one (pixel distance not the mm).
|
|
125
|
+
* Then update the changedWidth and changedHeight based on the sizeFoctor.
|
|
126
|
+
*/
|
|
127
|
+
updateOriginAndChangedWH(): void;
|
|
128
|
+
/**
|
|
129
|
+
* Keep all contrast slice index to same.
|
|
130
|
+
* Synchronize the slice indexes of all the contrasts so that they are consistent with the main slice's index.
|
|
131
|
+
*/
|
|
132
|
+
setSyncsliceNum(): void;
|
|
133
|
+
appendLoadingbar(loadingbar: HTMLDivElement): void;
|
|
134
|
+
clearStoreImages(): void;
|
|
135
|
+
/**
|
|
136
|
+
* Reset the draw and display canvases layout after mouse pan.
|
|
137
|
+
* If no params in, then center the draw and display canvases.
|
|
138
|
+
* @param l number, Offset to the left
|
|
139
|
+
* @param t number, Offset to the top
|
|
140
|
+
*/
|
|
141
|
+
resetPaintAreaUIPosition(l?: number, t?: number): void;
|
|
142
|
+
/**
|
|
143
|
+
* Clear masks on drawingCanvas layers.
|
|
144
|
+
*/
|
|
145
|
+
resetLayerCanvas(): void;
|
|
146
|
+
redrawMianPreOnDisplayCanvas(): void;
|
|
147
|
+
/**
|
|
148
|
+
* Resize the draw and display canvas size based on the input size factor number.
|
|
149
|
+
* @param factor number
|
|
150
|
+
*/
|
|
151
|
+
resizePaintArea(factor: number): void;
|
|
152
|
+
/**
|
|
153
|
+
* Used to init the mask on each label and reload
|
|
154
|
+
* @param paintImages
|
|
155
|
+
* @param ctx
|
|
156
|
+
*/
|
|
157
|
+
private reloadMaskToLabel;
|
|
158
|
+
/**
|
|
159
|
+
* flip the canvas to a correct position.
|
|
160
|
+
* This is because the slice canvas from threejs is not in a correct 2D postion.
|
|
161
|
+
* Thus, everytime when we redraw the display canvas, we need to flip to draw the origin canvas from threejs.
|
|
162
|
+
* Under different axis(sagittal, Axial, Coronal), the flip orientation is different.
|
|
163
|
+
*/
|
|
164
|
+
flipDisplayImageByAxis(): void;
|
|
165
|
+
private clearDictionary;
|
|
166
|
+
/**
|
|
167
|
+
* Set the empty canvas width and height based on the axis (pixel distance not the mm), to reduce duplicate codes.
|
|
168
|
+
*
|
|
169
|
+
* @param axis
|
|
170
|
+
*/
|
|
171
|
+
setEmptyCanvasSize(axis?: "x" | "y" | "z"): void;
|
|
172
|
+
/******************************** redraw display canvas ***************************************/
|
|
173
|
+
/**
|
|
174
|
+
* Redraw current contrast image to display canvas.
|
|
175
|
+
* It is more related to change the contrast slice image's window width or center.
|
|
176
|
+
*/
|
|
177
|
+
redrawDisplayCanvas(): void;
|
|
178
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|