brainsmatics 1.1.80 → 1.1.81

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 CHANGED
@@ -162,9 +162,9 @@ import {
162
162
 
163
163
  部分 3D 页面支持通过 URL query 参数恢复场景状态或加载数据。
164
164
 
165
- ### 通过 URL 加载 TIFF 数据
165
+ ### 通过 URL 加载 TIFF / NIfTI 数据
166
166
 
167
- `Auxiliary` 模块中有 `loadUrlTiffData` 逻辑,会读取以下参数:
167
+ 3D 页面可以通过 `UploadComponent` 读取以下参数,将 URL 数据作为场景文件加载,并支持选中后的位移、旋转、缩放、颜色和亮度等控制:
168
168
 
169
169
  ```text
170
170
  tiffDataPath
@@ -187,7 +187,22 @@ tiffInfo
187
187
  }
188
188
  ```
189
189
 
190
- `tiffDataPath` 必须是浏览器可以直接 `fetch` 到的 tif/tiff 地址。
190
+ `tiffDataPath` 必须是浏览器可以直接 `fetch` 到的 `.tif`、`.tiff`、`.nii` 或 `.nii.gz` 地址。`.nii/.nii.gz` 会按 `NiiGZ` 类型加载;其他情况默认按 `TIFF` 类型加载。
191
+
192
+ 如果 `tiffInfo` 中包含 `min`、`max`、`max_resample`,会用它们推导初始位置和缩放。`tiffInfo` 也可以附加或覆盖场景控制参数,例如:
193
+
194
+ ```json
195
+ {
196
+ "file_type": "NiiGZ",
197
+ "translateX": 0,
198
+ "translateY": -1.5,
199
+ "translateZ": 0,
200
+ "scaleX": 1,
201
+ "scaleY": 1,
202
+ "scaleZ": 1,
203
+ "resolution": 10
204
+ }
205
+ ```
191
206
 
192
207
  ### 恢复上传到场景中的文件
193
208
 
@@ -1,4 +1,4 @@
1
- import { i as r } from "./index-9c04856f.mjs";
1
+ import { i as r } from "./index-f5c96b65.mjs";
2
2
  import { B as o } from "./basedecoder-11034ec6.mjs";
3
3
  import "react";
4
4
  import "react-dom";
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-f2b2c4d0.js"),t=require("./basedecoder-0503cc54.js");require("react");require("react-dom");class d extends t.BaseDecoder{decodeBlock(e){return r.inflate_1(new Uint8Array(e)).buffer}}exports.default=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-5d1d538b.js"),t=require("./basedecoder-0503cc54.js");require("react");require("react-dom");class d extends t.BaseDecoder{decodeBlock(e){return r.inflate_1(new Uint8Array(e)).buffer}}exports.default=d;