@cornerstonejs/core 1.33.0 → 1.35.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cornerstonejs/core",
3
- "version": "1.33.0",
3
+ "version": "1.35.0",
4
4
  "description": "",
5
5
  "main": "src/index.ts",
6
6
  "types": "dist/types/index.d.ts",
@@ -47,5 +47,5 @@
47
47
  "type": "individual",
48
48
  "url": "https://ohif.org/donate"
49
49
  },
50
- "gitHead": "bcfcf24cacbc6d230a3ddc722823d5ecc05cbb6d"
50
+ "gitHead": "115719df9d081849d8ee1c3d9c39b3c2249be17c"
51
51
  }
@@ -0,0 +1,4 @@
1
+ // Axis-aligned bounding box 2D
2
+ type AABB2 = { minX: number; maxX: number; minY: number; maxY: number };
3
+
4
+ export type { AABB2 as default };
@@ -22,6 +22,7 @@ import type {
22
22
  } from './ILoadObject';
23
23
  import type Metadata from './Metadata';
24
24
  import type OrientationVectors from './OrientationVectors';
25
+ import type AABB2 from './AABB2';
25
26
  import type Point2 from './Point2';
26
27
  import type Point3 from './Point3';
27
28
  import type Point4 from './Point4';
@@ -153,6 +154,7 @@ export type {
153
154
  //
154
155
  Metadata,
155
156
  OrientationVectors,
157
+ AABB2,
156
158
  Point2,
157
159
  Point3,
158
160
  Point4,
@@ -1,5 +1,5 @@
1
1
  import { vec3, mat4 } from 'gl-matrix';
2
- import { IStackViewport } from '../types';
2
+ import { IStackViewport, IVolumeViewport } from '../types';
3
3
  import spatialRegistrationMetadataProvider from './spatialRegistrationMetadataProvider';
4
4
  import { metaData } from '..';
5
5
 
@@ -24,8 +24,8 @@ const ALLOWED_DELTA = 0.05;
24
24
  * @param viewport2 - The second stack viewport
25
25
  */
26
26
  function calculateViewportsSpatialRegistration(
27
- viewport1: IStackViewport,
28
- viewport2: IStackViewport
27
+ viewport1: IStackViewport | IVolumeViewport,
28
+ viewport2: IStackViewport | IVolumeViewport
29
29
  ): void {
30
30
  const imageId1 = viewport1.getCurrentImageId();
31
31
  const imageId2 = viewport2.getCurrentImageId();