From 2c4a8d4cf9c4f00bd41857af1a7fc78943a5f8bc Mon Sep 17 00:00:00 2001 From: LinkunGao Date: Mon, 1 May 2023 12:50:47 +1200 Subject: [PATCH 1/3] update threejs latest version --- package-lock.json | 39 ++++++---------------------------- package.json | 3 +-- src/Loader/copperNrrdLoader.ts | 11 +++++----- 3 files changed, 13 insertions(+), 40 deletions(-) diff --git a/package-lock.json b/package-lock.json index e147db1..ad4892f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,14 +12,13 @@ "@types/dat.gui": "^0.7.9", "@types/three": "^0.140.0", "copper3d_plugin_heart_k": "^1.0.14", - "copper3d_plugin_nrrd": "^1.3.2", "dat.gui": "^0.7.9", "dicom-parser": "^1.8.13", "fflate": "^0.7.3", "file-saver": "^2.0.5", "glsl-blend-soft-light": "^1.0.5", "glsl-film-grain": "^1.0.4", - "three": "^0.150.1" + "three": "^0.152.2" }, "devDependencies": { "@rollup/plugin-image": "^2.1.1", @@ -514,19 +513,6 @@ "version": "1.0.8", "license": "ISC" }, - "node_modules/copper3d_plugin_nrrd": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/copper3d_plugin_nrrd/-/copper3d_plugin_nrrd-1.3.2.tgz", - "integrity": "sha512-vP1rDEDZZWRQGnDfV80Ok/A1WfwLD+04N9az7PE/DRoBiOBEW3ByoLUrrK1Gxsq1Tgt8+uFAavxqynE4u697Qw==", - "dependencies": { - "fflate": "^0.7.4", - "three": "^0.148.0" - } - }, - "node_modules/copper3d_plugin_nrrd/node_modules/three": { - "version": "0.148.0", - "license": "MIT" - }, "node_modules/core-util-is": { "version": "1.0.3", "dev": true, @@ -2655,8 +2641,9 @@ } }, "node_modules/three": { - "version": "0.150.1", - "license": "MIT" + "version": "0.152.2", + "resolved": "https://registry.npmjs.org/three/-/three-0.152.2.tgz", + "integrity": "sha512-Ff9zIpSfkkqcBcpdiFo2f35vA9ZucO+N8TNacJOqaEE6DrB0eufItVMib8bK8Pcju/ZNT6a7blE1GhTpkdsILw==" }, "node_modules/through2": { "version": "2.0.5", @@ -3089,20 +3076,6 @@ "copper3d_plugin_heartjs_config": { "version": "1.0.8" }, - "copper3d_plugin_nrrd": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/copper3d_plugin_nrrd/-/copper3d_plugin_nrrd-1.3.2.tgz", - "integrity": "sha512-vP1rDEDZZWRQGnDfV80Ok/A1WfwLD+04N9az7PE/DRoBiOBEW3ByoLUrrK1Gxsq1Tgt8+uFAavxqynE4u697Qw==", - "requires": { - "fflate": "^0.7.4", - "three": "^0.148.0" - }, - "dependencies": { - "three": { - "version": "0.148.0" - } - } - }, "core-util-is": { "version": "1.0.3", "dev": true @@ -4451,7 +4424,9 @@ } }, "three": { - "version": "0.150.1" + "version": "0.152.2", + "resolved": "https://registry.npmjs.org/three/-/three-0.152.2.tgz", + "integrity": "sha512-Ff9zIpSfkkqcBcpdiFo2f35vA9ZucO+N8TNacJOqaEE6DrB0eufItVMib8bK8Pcju/ZNT6a7blE1GhTpkdsILw==" }, "through2": { "version": "2.0.5", diff --git a/package.json b/package.json index 8fba602..7d3a5b7 100644 --- a/package.json +++ b/package.json @@ -48,13 +48,12 @@ "@types/dat.gui": "^0.7.9", "@types/three": "^0.140.0", "copper3d_plugin_heart_k": "^1.0.14", - "copper3d_plugin_nrrd": "^1.3.2", "dat.gui": "^0.7.9", "dicom-parser": "^1.8.13", "fflate": "^0.7.3", "file-saver": "^2.0.5", "glsl-blend-soft-light": "^1.0.5", "glsl-film-grain": "^1.0.4", - "three": "^0.150.1" + "three": "^0.152.2" } } diff --git a/src/Loader/copperNrrdLoader.ts b/src/Loader/copperNrrdLoader.ts index 4cb3691..19070e8 100644 --- a/src/Loader/copperNrrdLoader.ts +++ b/src/Loader/copperNrrdLoader.ts @@ -1,7 +1,7 @@ import * as THREE from "three"; -// import { NRRDLoader } from "three/examples/jsm/loaders/NRRDLoader"; +import { NRRDLoader } from "three/examples/jsm/loaders/NRRDLoader"; // import * as NRRD from "copper3d_plugin_nrrd"; -import { NRRDLoader } from "copper3d_plugin_nrrd"; +// import { NRRDLoader } from "copper3d_plugin_nrrd"; import copperScene from "../Scene/copperScene"; import { VolumeRenderShader1 } from "three/examples/jsm/shaders/VolumeShader"; @@ -21,7 +21,7 @@ loader = new NRRDLoader(); let cube: THREE.Mesh; let gui: GUI | undefined; -let oldGuiDom:HTMLDivElement; +let oldGuiDom: HTMLDivElement; let CircleGeometry = new THREE.RingGeometry(5, 6, 30); let CircleMaterial = new THREE.MeshBasicMaterial({ @@ -159,7 +159,7 @@ export function copperNrrdLoader( } else { callback && callback(volume, nrrdMeshes, nrrdSlices); } - gui = undefined + gui = undefined; }, function (xhr: ProgressEvent) { loadingContainer.style.display = "flex"; @@ -429,10 +429,9 @@ export function addBoxHelper( } function configGui(opts?: optsType) { - if (opts && opts.openGui) { if (opts.container) { - if(oldGuiDom){ + if (oldGuiDom) { opts.container.removeChild(oldGuiDom); } gui = new GUI({ From 66df58e4e805e8482ecdda8dcc12d9710b5b0b65 Mon Sep 17 00:00:00 2001 From: LinkunGao Date: Mon, 1 May 2023 12:51:13 +1200 Subject: [PATCH 2/3] update docs --- docs/source/conf.py | 2 +- docs/source/release/release.md | 4 ++++ src/index.ts | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 2e08e93..7c1ef6f 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -22,7 +22,7 @@ author = 'LinkunGao' # The full version, including alpha/beta/rc tags -release = 'v1.14.8' +release = 'v1.14.9' # -- General configuration --------------------------------------------------- diff --git a/docs/source/release/release.md b/docs/source/release/release.md index db2b0bf..7360388 100644 --- a/docs/source/release/release.md +++ b/docs/source/release/release.md @@ -1634,3 +1634,7 @@ sceneIn?.loadNrrd(url, loadBar1, false, funa, opts); - add prerender function in copperRenderer. - remove gltf exporter for nuxt + +## Release v1.14.9 + +- update threejs latest version. diff --git a/src/index.ts b/src/index.ts index 1df4fff..2957a3e 100644 --- a/src/index.ts +++ b/src/index.ts @@ -36,10 +36,10 @@ import { import "./css/style.css"; -export const REVISION = "v1.14.8"; +export const REVISION = "v1.14.9"; console.log( - "%cCopper3D Visualisation %cBeta:v1.14.8", + "%cCopper3D Visualisation %cBeta:v1.14.9", "padding: 3px;color:white; background:#023047", "padding: 3px;color:white; background:#f50a25" ); From 2209387f96d2e506e52af29c97ec7f949ed31c82 Mon Sep 17 00:00:00 2001 From: LinkunGao Date: Mon, 1 May 2023 12:53:57 +1200 Subject: [PATCH 3/3] 1.14.9 --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index ad4892f..590bd06 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "copper3d_visualisation", - "version": "1.14.8", + "version": "1.14.9", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "copper3d_visualisation", - "version": "1.14.8", + "version": "1.14.9", "license": "Apache-2.0", "dependencies": { "@types/dat.gui": "^0.7.9", diff --git a/package.json b/package.json index 7d3a5b7..5abca7a 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "copper3d_visualisation", "description": "A 3d visualisation package base on threejs provides multiple scenes and Nrrd image load funtion.", - "version": "1.14.8", + "version": "1.14.9", "main": "dist/bundle.umd.js", "moudle": "dist/bundle.esm.js", "types": "dist/types/index.d.ts",