@cornerstonejs/core 0.42.1 → 0.42.3
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/dist/cjs/RenderingEngine/StackViewport.js +4 -4
- package/dist/cjs/RenderingEngine/StackViewport.js.map +1 -1
- package/dist/cjs/utilities/isEqual.js +0 -5
- package/dist/cjs/utilities/isEqual.js.map +1 -1
- package/dist/esm/RenderingEngine/StackViewport.js +4 -4
- package/dist/esm/RenderingEngine/StackViewport.js.map +1 -1
- package/dist/esm/utilities/isEqual.js +0 -5
- package/dist/esm/utilities/isEqual.js.map +1 -1
- package/dist/umd/index.js +1 -1
- package/dist/umd/index.js.map +1 -1
- package/package.json +2 -2
- package/src/RenderingEngine/StackViewport.ts +4 -4
- package/src/utilities/isEqual.ts +0 -9
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cornerstonejs/core",
|
|
3
|
-
"version": "0.42.
|
|
3
|
+
"version": "0.42.3",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/umd/index.js",
|
|
6
6
|
"types": "dist/esm/index.d.ts",
|
|
@@ -51,5 +51,5 @@
|
|
|
51
51
|
"type": "individual",
|
|
52
52
|
"url": "https://ohif.org/donate"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "f3db864a642cb3a4e56dd19b2fedaa6815bcf3a7"
|
|
55
55
|
}
|
|
@@ -1537,15 +1537,15 @@ class StackViewport extends Viewport implements IStackViewport {
|
|
|
1537
1537
|
const dataType = imageData.getPointData().getScalars().getDataType();
|
|
1538
1538
|
|
|
1539
1539
|
// using epsilon comparison for float numbers comparison.
|
|
1540
|
-
const isSameXSpacing = isEqual(xSpacing, image.
|
|
1541
|
-
const isSameYSpacing = isEqual(ySpacing, image.
|
|
1540
|
+
const isSameXSpacing = isEqual(xSpacing, image.columnPixelSpacing);
|
|
1541
|
+
const isSameYSpacing = isEqual(ySpacing, image.rowPixelSpacing);
|
|
1542
1542
|
|
|
1543
1543
|
// using spacing, size, and direction only for now
|
|
1544
1544
|
return (
|
|
1545
1545
|
(isSameXSpacing ||
|
|
1546
|
-
(image.
|
|
1546
|
+
(image.columnPixelSpacing === null && xSpacing === 1.0)) &&
|
|
1547
1547
|
(isSameYSpacing ||
|
|
1548
|
-
(image.
|
|
1548
|
+
(image.rowPixelSpacing === null && ySpacing === 1.0)) &&
|
|
1549
1549
|
xVoxels === image.columns &&
|
|
1550
1550
|
yVoxels === image.rows &&
|
|
1551
1551
|
isEqual(imagePlaneModule.rowCosines, <Point3>rowCosines) &&
|
package/src/utilities/isEqual.ts
CHANGED
|
@@ -53,15 +53,6 @@ export default function isEqual<ValueType>(
|
|
|
53
53
|
return false;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
// typeof object must have same constructor
|
|
57
|
-
if (
|
|
58
|
-
typeof v1 === 'object' &&
|
|
59
|
-
typeof v2 === 'object' &&
|
|
60
|
-
v1.constructor !== v2.constructor
|
|
61
|
-
) {
|
|
62
|
-
return false;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
56
|
if (isNumberType(v1) && isNumberType(v2)) {
|
|
66
57
|
return areNumbersEqualWithTolerance(v1, v2, tolerance);
|
|
67
58
|
}
|