hellfire 0.22.1 → 0.22.2

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/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ## [0.22.2](http://10.16.100.57/diffusion/115/paladin/compare/v0.22.1...v0.22.2) (2022-07-08)
6
+
7
+
8
+
5
9
  ## [0.22.1](http://10.16.100.57/diffusion/115/paladin/compare/v0.22.0...v0.22.1) (2022-07-07)
6
10
 
7
11
 
package/dist/index.js CHANGED
@@ -14200,6 +14200,10 @@ var ImageProcessorWorkerBase = /*#__PURE__*/function () {
14200
14200
  throw new InvalidImageException("LoadImage 参数不能为空.");
14201
14201
  }
14202
14202
 
14203
+ if (param.images.length <= 3) {
14204
+ throw new LoadImageException("序列影像数必须多于3张");
14205
+ }
14206
+
14203
14207
  if (!ImageProcessorWorkerBase.canImagesProcess(param.images)) {
14204
14208
  throw new InvalidImageException("该序列中影像参数不一致[如 宽/高/方位].");
14205
14209
  }
@@ -14208,7 +14212,6 @@ var ImageProcessorWorkerBase = /*#__PURE__*/function () {
14208
14212
 
14209
14213
  try {
14210
14214
  if (param.images === undefined) throw new LoadImageException("LoadImage 参数不能为空");
14211
- if (param.images.length <= 3) throw new LoadImageException("序列影像数不能少于3张");
14212
14215
  var logger = new RuntimeLogger(this.loadImages.name);
14213
14216
  this.init(param);
14214
14217
  this.loadImagesInternal(ImageProcessorWorkerBase.converToImageModel(param.images), param);
@@ -14515,13 +14518,31 @@ var ImageProcessorWorkerBase = /*#__PURE__*/function () {
14515
14518
  }], [{
14516
14519
  key: "canImagesProcess",
14517
14520
  value: function canImagesProcess(images) {
14518
- if (!images || images.length < 3) return false;
14519
14521
  var imageModels = ImageProcessorWorkerBase.converToImageModel(images, false);
14520
14522
  var firstImage = imageModels[0];
14521
14523
 
14522
14524
  for (var i = 1; i < imageModels.length; i++) {
14523
14525
  var checkImage = imageModels[i];
14524
- if (firstImage.imageWidth !== checkImage.imageWidth || firstImage.imageHeight !== checkImage.imageHeight || Math.abs(firstImage.orientation[0] - checkImage.orientation[0]) > 0.0001 || Math.abs(firstImage.orientation[1] - checkImage.orientation[1]) > 0.0001 || Math.abs(firstImage.orientation[2] - checkImage.orientation[2]) > 0.0001 || Math.abs(firstImage.orientation[3] - checkImage.orientation[3]) > 0.0001 || Math.abs(firstImage.orientation[4] - checkImage.orientation[4]) > 0.0001 || Math.abs(firstImage.orientation[5] - checkImage.orientation[5]) > 0.0001) return false;
14526
+
14527
+ if (!firstImage.imageWidth || !firstImage.imageHeight || !checkImage.imageWidth || !checkImage.imageHeight) {
14528
+ console.log('[vtk - image process check] 宽高缺失');
14529
+ return false;
14530
+ }
14531
+
14532
+ if (!firstImage.orientation || !checkImage.orientation) {
14533
+ console.log('[vtk - image process check] 方位缺失');
14534
+ return false;
14535
+ }
14536
+
14537
+ if (firstImage.imageWidth !== checkImage.imageWidth || firstImage.imageHeight !== checkImage.imageHeight) {
14538
+ console.log('[vtk - image process check] 宽高不一致');
14539
+ return false;
14540
+ }
14541
+
14542
+ if (Math.abs(firstImage.orientation[0] - checkImage.orientation[0]) > 0.0001 || Math.abs(firstImage.orientation[1] - checkImage.orientation[1]) > 0.0001 || Math.abs(firstImage.orientation[2] - checkImage.orientation[2]) > 0.0001 || Math.abs(firstImage.orientation[3] - checkImage.orientation[3]) > 0.0001 || Math.abs(firstImage.orientation[4] - checkImage.orientation[4]) > 0.0001 || Math.abs(firstImage.orientation[5] - checkImage.orientation[5]) > 0.0001) {
14543
+ console.log('[vtk - image process check] 方位不一致');
14544
+ return false;
14545
+ }
14525
14546
  }
14526
14547
 
14527
14548
  return true;
@@ -45685,35 +45706,35 @@ var DicomToolFlattenMode = /*#__PURE__*/function (_Component) {
45685
45706
  onClick: function onClick(e) {
45686
45707
  e.stopPropagation();
45687
45708
 
45688
- if (!MIP) {
45709
+ if (!VR) {
45689
45710
  if (isThree) {
45690
45711
  exit3D();
45691
45712
  }
45692
45713
 
45693
- start3D('MIP');
45714
+ start3D('VR');
45694
45715
  }
45695
45716
  },
45696
- className: MIP ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
45717
+ className: VR ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
45697
45718
  style: {
45698
45719
  borderRight: '1px solid #5b5b5b'
45699
45720
  }
45700
- }, "MIP"), IODisconnect && /*#__PURE__*/React__default.createElement("div", {
45721
+ }, "VR"), IODisconnect && /*#__PURE__*/React__default.createElement("div", {
45701
45722
  onClick: function onClick(e) {
45702
45723
  e.stopPropagation();
45703
45724
 
45704
- if (!VR) {
45725
+ if (!MIP) {
45705
45726
  if (isThree) {
45706
45727
  exit3D();
45707
45728
  }
45708
45729
 
45709
- start3D('VR');
45730
+ start3D('MIP');
45710
45731
  }
45711
45732
  },
45712
- className: VR ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
45733
+ className: MIP ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
45713
45734
  style: {
45714
45735
  borderRight: '1px solid #5b5b5b'
45715
45736
  }
45716
- }, "VR")), showBaseTools && /*#__PURE__*/React__default.createElement("div", {
45737
+ }, "MIP")), showBaseTools && /*#__PURE__*/React__default.createElement("div", {
45717
45738
  className: "paladin-flex-row"
45718
45739
  }, commonTools && commonTools.map(function (item, i) {
45719
45740
  return /*#__PURE__*/React__default.createElement(DicomToolItemPlus, _extends_1({}, _this2.props, {
@@ -46025,32 +46046,32 @@ var DicomToolFlattenMode$1 = /*#__PURE__*/function (_Component) {
46025
46046
  onClick: function onClick(e) {
46026
46047
  e.stopPropagation();
46027
46048
 
46028
- if (!MIP) {
46049
+ if (!VR) {
46029
46050
  if (isThree) {
46030
46051
  exit3D();
46031
46052
  }
46032
46053
 
46033
- start3D('MIP');
46054
+ start3D('VR');
46034
46055
  }
46035
46056
  },
46036
- className: MIP ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
46037
- style: {
46038
- borderRight: '1px solid #5b5b5b'
46039
- }
46040
- }, "MIP"), IODisconnect && /*#__PURE__*/React__default.createElement("div", {
46057
+ className: VR ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav'
46058
+ }, "VR"), IODisconnect && /*#__PURE__*/React__default.createElement("div", {
46041
46059
  onClick: function onClick(e) {
46042
46060
  e.stopPropagation();
46043
46061
 
46044
- if (!VR) {
46062
+ if (!MIP) {
46045
46063
  if (isThree) {
46046
46064
  exit3D();
46047
46065
  }
46048
46066
 
46049
- start3D('VR');
46067
+ start3D('MIP');
46050
46068
  }
46051
46069
  },
46052
- className: VR ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav'
46053
- }, "VR")), showBaseTools && /*#__PURE__*/React__default.createElement("div", {
46070
+ className: MIP ? 'paladin-tool-nav paladin-tool-nav-active' : 'paladin-tool-nav',
46071
+ style: {
46072
+ borderRight: '1px solid #5b5b5b'
46073
+ }
46074
+ }, "MIP")), showBaseTools && /*#__PURE__*/React__default.createElement("div", {
46054
46075
  className: "paladin-flex-col paladin-flex-1 paladin-hor-border",
46055
46076
  style: {
46056
46077
  flex: MPR ? 3 : 2
@@ -47174,7 +47195,7 @@ var _default$_ = function _default(images) {
47174
47195
 
47175
47196
 
47176
47197
  if (images.length <= 3) {
47177
- return "序列影像数不能少于3张";
47198
+ return "序列影像数必须多于3张";
47178
47199
  }
47179
47200
 
47180
47201
  var checkResult = imageProcessCheckError(images);