Skip to content

Commit

Permalink
Merge branch 'cornerstonejs:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
kom482 authored May 30, 2024
2 parents 9e0369e + f35943f commit f736d84
Show file tree
Hide file tree
Showing 112 changed files with 3,476 additions and 3,275 deletions.
84 changes: 84 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,90 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## [1.77.2](https://github.com/cornerstonejs/cornerstone3D/compare/v1.77.1...v1.77.2) (2024-05-29)

### Bug Fixes

- **seg:** Handle useSharedArrayBuffer configuration properly in volume creation ([#1290](https://github.com/cornerstonejs/cornerstone3D/issues/1290)) ([561bd4b](https://github.com/cornerstonejs/cornerstone3D/commit/561bd4bcd556d968b8e4f9ec48061aaeb434e045))

## [1.77.1](https://github.com/cornerstonejs/cornerstone3D/compare/v1.77.0...v1.77.1) (2024-05-29)

### Bug Fixes

- **contour:** set default for renderFill to true ([#1289](https://github.com/cornerstonejs/cornerstone3D/issues/1289)) ([ca86dbb](https://github.com/cornerstonejs/cornerstone3D/commit/ca86dbbbf4efd8dd29c14a5d8e50e8adc703b265))

# [1.77.0](https://github.com/cornerstonejs/cornerstone3D/compare/v1.76.1...v1.77.0) (2024-05-28)

### Features

- **nifti:** update nifti-reader-js to 0.6.8 ([#1286](https://github.com/cornerstonejs/cornerstone3D/issues/1286)) ([e3704cd](https://github.com/cornerstonejs/cornerstone3D/commit/e3704cd1889b19549acde27ba97b642c27dd87e5))

## [1.76.1](https://github.com/cornerstonejs/cornerstone3D/compare/v1.76.0...v1.76.1) (2024-05-28)

**Note:** Version bump only for package root

# [1.76.0](https://github.com/cornerstonejs/cornerstone3D/compare/v1.75.2...v1.76.0) (2024-05-28)

### Features

- Add render to canvas for mpr/volume viewports ([#1215](https://github.com/cornerstonejs/cornerstone3D/issues/1215)) ([e400277](https://github.com/cornerstonejs/cornerstone3D/commit/e4002774bcedeb2334d008cb3ab3e294ff1c088b))

## [1.75.2](https://github.com/cornerstonejs/cornerstone3D/compare/v1.75.1...v1.75.2) (2024-05-28)

### Bug Fixes

- **core:** correctly set the orientation of the volume ([#1287](https://github.com/cornerstonejs/cornerstone3D/issues/1287)) ([9637dfb](https://github.com/cornerstonejs/cornerstone3D/commit/9637dfbb64eeb39d92c979d5922604079847b1e9))

## [1.75.1](https://github.com/cornerstonejs/cornerstone3D/compare/v1.75.0...v1.75.1) (2024-05-28)

### Bug Fixes

- **color:** Fix RGB inconsistencies ([#829](https://github.com/cornerstonejs/cornerstone3D/issues/829)) ([2fc22bc](https://github.com/cornerstonejs/cornerstone3D/commit/2fc22bcd1c0cac22b88e964699d55c51bd83283e))

# [1.75.0](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.8...v1.75.0) (2024-05-28)

### Features

- **nifti:** NIFTI data type enhancement ([#1219](https://github.com/cornerstonejs/cornerstone3D/issues/1219)) ([03a2335](https://github.com/cornerstonejs/cornerstone3D/commit/03a233525a67ac9bc6bc9a6d144334e67756f11f))

## [1.74.8](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.7...v1.74.8) (2024-05-24)

### Bug Fixes

- **measurements:** include volumeid and other useful properties in annotation metadata ([#1281](https://github.com/cornerstonejs/cornerstone3D/issues/1281)) ([8f4ff3e](https://github.com/cornerstonejs/cornerstone3D/commit/8f4ff3e3b836ca4d5817f90ac7349232635cdac1))

## [1.74.7](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.6...v1.74.7) (2024-05-23)

### Bug Fixes

- **crosshairs:** configurable viewportIndicators ([#1268](https://github.com/cornerstonejs/cornerstone3D/issues/1268)) ([268f1b1](https://github.com/cornerstonejs/cornerstone3D/commit/268f1b1d6bd99781d707c57b7afc764d7f26c824))

## [1.74.6](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.5...v1.74.6) (2024-05-23)

### Bug Fixes

- **metaData:** transfer syntax retrieval in metaDataProvider ([#1273](https://github.com/cornerstonejs/cornerstone3D/issues/1273)) ([a10b9f1](https://github.com/cornerstonejs/cornerstone3D/commit/a10b9f19926899804a4e7926a77839a6c156219c))

## [1.74.5](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.4...v1.74.5) (2024-05-22)

### Bug Fixes

- **rt:** assign correct imageId for Stack ([#1269](https://github.com/cornerstonejs/cornerstone3D/issues/1269)) ([4845045](https://github.com/cornerstonejs/cornerstone3D/commit/48450453eca53ed7f54e2a0b8fe8ff1ce3b8d3e1))

## [1.74.4](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.3...v1.74.4) (2024-05-21)

### Bug Fixes

- **rendering:** Allow memory sizes between 2gb and 4gb by using wasm allocation ([#1260](https://github.com/cornerstonejs/cornerstone3D/issues/1260)) ([a00952e](https://github.com/cornerstonejs/cornerstone3D/commit/a00952e0dc7d1563855dbe4b140d8c478c2b1788))

## [1.74.3](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.2...v1.74.3) (2024-05-21)

**Note:** Version bump only for package root

## [1.74.2](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.1...v1.74.2) (2024-05-21)

**Note:** Version bump only for package root

## [1.74.1](https://github.com/cornerstonejs/cornerstone3D/compare/v1.74.0...v1.74.1) (2024-05-17)

### Bug Fixes
Expand Down
2 changes: 1 addition & 1 deletion commit.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
03a51a2f81f2126926c7bead455de58d5b364990
561bd4bcd556d968b8e4f9ec48061aaeb434e045
101 changes: 15 additions & 86 deletions common/reviews/api/core.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ type ActorSliceRange = {
};

// @public (undocumented)
export function addImageSlicesToViewports(renderingEngine: IRenderingEngine, stackInputs: Array<IStackInput>, viewportIds: Array<string>, immediateRender?: boolean, suppressEvents?: boolean): Promise<void>;
export function addImageSlicesToViewports(renderingEngine: IRenderingEngine, stackInputs: Array<IStackInput>, viewportIds: Array<string>): Promise<void>;

// @public (undocumented)
function addProvider(provider: (type: string, ...query: string[]) => any, priority?: number): void;
Expand Down Expand Up @@ -230,7 +230,7 @@ declare namespace cacheUtils {
}

// @public (undocumented)
function calculateViewportsSpatialRegistration(viewport1: IStackViewport | IVolumeViewport, viewport2: IStackViewport | IVolumeViewport): void;
function calculateViewportsSpatialRegistration(viewport1: StackViewport | IVolumeViewport, viewport2: StackViewport | IVolumeViewport): void;

// @public (undocumented)
enum CalibrationTypes {
Expand Down Expand Up @@ -376,7 +376,7 @@ enum ContourType {

// @public (undocumented)
function convertStackToVolumeViewport({ viewport, options, }: {
viewport: IStackViewport;
viewport: StackViewport;
options: {
volumeId: string;
viewportId?: string;
Expand Down Expand Up @@ -991,7 +991,7 @@ function getBufferConfiguration(targetBufferType: PixelDataTypedArrayString, len
function getClosestImageId(imageVolume: IImageVolume, worldPos: Point3, viewPlaneNormal: Point3): string;

// @public (undocumented)
function getClosestStackImageIndexForPoint(point: Point3, viewport: IStackViewport): number | null;
function getClosestStackImageIndexForPoint(point: Point3, viewport: StackViewport): number | null;

// @public (undocumented)
function getColormap(name: any): any;
Expand Down Expand Up @@ -1088,7 +1088,7 @@ function getTransferFunctionNodes(transferFunction: any): any[];
function getUnknownVolumeLoaderSchema(): string;

// @public (undocumented)
function getViewportImageCornersInWorld(viewport: IStackViewport | IVolumeViewport): Point3[];
function getViewportImageCornersInWorld(viewport: StackViewport | IVolumeViewport): Point3[];

// @public (undocumented)
function getViewportImageIds(viewport: IViewport): string[];
Expand Down Expand Up @@ -1339,7 +1339,7 @@ interface IEnabledElement {
// (undocumented)
renderingEngineId: string;
// (undocumented)
viewport: IStackViewport | IVolumeViewport;
viewport: StackViewport | IVolumeViewport;
// (undocumented)
viewportId: string;
}
Expand Down Expand Up @@ -2005,7 +2005,7 @@ interface IRenderingEngine {
// (undocumented)
fillCanvasWithBackgroundColor(canvas: HTMLCanvasElement, backgroundColor: [number, number, number]): void;
// (undocumented)
getStackViewports(): Array<IStackViewport>;
getStackViewports(): Array<StackViewport>;
// (undocumented)
getVideoViewports(): Array<IVideoViewport>;
// (undocumented)
Expand Down Expand Up @@ -2079,79 +2079,6 @@ interface IStackInput {
visibility?: boolean;
}

// @public (undocumented)
interface IStackViewport extends IViewport {
// (undocumented)
addImages(stackInputs: Array<IStackInput>, immediateRender: boolean, suppressEvents: boolean): any;
// (undocumented)
calibrateSpacing(imageId: string): void;
// (undocumented)
canvasToWorld: (canvasPos: Point2) => Point3;
// (undocumented)
clearDefaultProperties(imageId?: string): void;
// (undocumented)
customRenderViewportToCanvas: () => {
canvas: HTMLCanvasElement;
element: HTMLDivElement;
viewportId: string;
renderingEngineId: string;
};
// (undocumented)
getCamera(): ICamera;
// (undocumented)
getCornerstoneImage: () => IImage;
// (undocumented)
getCurrentImageId: () => string;
// (undocumented)
getCurrentImageIdIndex: () => number;
// (undocumented)
getDefaultProperties: (imageId?: string) => StackViewportProperties;
// (undocumented)
getFrameOfReferenceUID: () => string;
// (undocumented)
getImageData(): IImageData | CPUIImageData;
// (undocumented)
getImageDataMetadata(image: IImage): any;
// (undocumented)
getImageIds: () => string[];
// (undocumented)
getProperties: () => StackViewportProperties;
// (undocumented)
getRenderer(): any;
// (undocumented)
hasImageId: (imageId: string) => boolean;
// (undocumented)
hasImageURI: (imageURI: string) => boolean;
// (undocumented)
modality: string;
// (undocumented)
resetCamera(resetPan?: boolean, resetZoom?: boolean): boolean;
// (undocumented)
resetProperties(): void;
// (undocumented)
resetToDefaultProperties(): void;
// (undocumented)
resize: () => void;
// (undocumented)
scaling: Scaling;
// (undocumented)
setCamera(cameraInterface: ICamera): void;
// (undocumented)
setDefaultProperties(ViewportProperties: StackViewportProperties, imageId?: string): void;
// (undocumented)
setImageIdIndex(imageIdIndex: number): Promise<string>;
// (undocumented)
setProperties({ voiRange, invert, interpolationType, rotation, colormap, }: StackViewportProperties, suppressEvents?: boolean): void;
// (undocumented)
setStack(imageIds: Array<string>, currentImageIdIndex?: number): Promise<string>;
// (undocumented)
stackActorReInitialized: boolean;
// (undocumented)
unsetColormap(): void;
// (undocumented)
worldToCanvas: (worldPos: Point3) => Point2;
}

// @public (undocumented)
interface IStreamingImageVolume extends ImageVolume {
// (undocumented)
Expand Down Expand Up @@ -2476,7 +2403,7 @@ function loadAndCacheImages(imageIds: Array<string>, options?: ImageLoaderOption
function loadImage(imageId: string, options?: ImageLoaderOptions): Promise<IImage>;

// @public (undocumented)
function loadImageToCanvas(options: LoadImageOptions): Promise<string>;
function loadImageToCanvas(options: LoadImageOptions): Promise<CanvasLoadPosition>;

// @public (undocumented)
function loadVolume(volumeId: string, options?: VolumeLoaderOptions): Promise<IImageVolume>;
Expand Down Expand Up @@ -2865,7 +2792,7 @@ export class RenderingEngine implements IRenderingEngine {
// (undocumented)
fillCanvasWithBackgroundColor(canvas: HTMLCanvasElement, backgroundColor: [number, number, number]): void;
// (undocumented)
getStackViewports(): Array<IStackViewport>;
getStackViewports(): Array<StackViewport>;
// (undocumented)
getVideoViewports(): Array<IVideoViewport>;
// (undocumented)
Expand Down Expand Up @@ -2897,10 +2824,12 @@ export class RenderingEngine implements IRenderingEngine {
}

// @public (undocumented)
function renderToCanvasCPU(canvas: HTMLCanvasElement, image: IImage, modality?: string, _renderingEngineId?: string, _viewportOptions?: ViewportInputOptions): Promise<string>;
function renderToCanvasCPU(canvas: HTMLCanvasElement, imageOrVolume: IImage | IVolume, modality?: string, _renderingEngineId?: string, _viewportOptions?: ViewportInputOptions): Promise<CanvasLoadPosition>;

// @public (undocumented)
function renderToCanvasGPU(canvas: HTMLCanvasElement, image: IImage, modality?: any, renderingEngineId?: string, viewportOptions?: ViewportInputOptions): Promise<string>;
function renderToCanvasGPU(canvas: HTMLCanvasElement, imageOrVolume: IImage | IVolume, modality?: any, renderingEngineId?: string, viewportOptions?: ViewportInputOptions & {
viewReference?: ViewReference;
}): Promise<CanvasLoadPosition>;

// @public (undocumented)
enum RequestType {
Expand Down Expand Up @@ -3114,7 +3043,7 @@ type StackNewImageEventDetail = {
};

// @public (undocumented)
export class StackViewport extends Viewport implements IStackViewport, IImagesLoader {
export class StackViewport extends Viewport implements StackViewport, IImagesLoader {
constructor(props: ViewportInput);
// (undocumented)
addActor: (actorEntry: ActorEntry) => void;
Expand Down Expand Up @@ -3392,7 +3321,7 @@ declare namespace Types {
IImagesLoader,
Cornerstone3DConfig,
ICamera,
IStackViewport,
StackViewport as IStackViewport,
IVideoViewport,
IVolumeViewport,
IEnabledElement,
Expand Down
16 changes: 13 additions & 3 deletions common/reviews/api/nifti-volume-loader.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@
```ts

import type { GetGPUTier } from 'detect-gpu';
import type { mat4 } from 'gl-matrix';
import { mat4 } from 'gl-matrix';
import type { TierResult } from 'detect-gpu';
import type vtkActor from '@kitware/vtk.js/Rendering/Core/Actor';
import type { vtkCamera } from '@kitware/vtk.js/Rendering/Core/Camera';
import vtkImageData from '@kitware/vtk.js/Common/DataModel/ImageData';
import vtkImageSlice from '@kitware/vtk.js/Rendering/Core/ImageSlice';
import type { vtkObject } from '@kitware/vtk.js/interfaces';
import vtkPlane from '@kitware/vtk.js/Common/DataModel/Plane';
import type vtkVolume from '@kitware/vtk.js/Rendering/Core/Volume';

// @public (undocumented)
Expand Down Expand Up @@ -43,10 +46,17 @@ declare namespace helpers {
export { helpers }

// @public (undocumented)
function makeVolumeMetadata(niftiHeader: any, orientation: any, scalarData: any): Types.Metadata;
function makeVolumeMetadata(niftiHeader: any, orientation: any, scalarData: any, pixelRepresentation: any): {
volumeMetadata: Types.Metadata;
dimensions: Types.Point3;
direction: Types.Mat3;
};

// @public (undocumented)
function modalityScaleNifti(array: Float32Array | Int16Array | Uint8Array, niftiHeader: any): void;
function modalityScaleNifti(niftiHeader: any, niftiImageBuffer: any): {
scalarData: Types.PixelDataTypedArray;
pixelRepresentation: number;
};

// @public (undocumented)
export class NiftiImageVolume extends ImageVolume {
Expand Down
5 changes: 4 additions & 1 deletion common/reviews/api/streaming-image-volume-loader.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@
```ts

import type { GetGPUTier } from 'detect-gpu';
import type { mat4 } from 'gl-matrix';
import { mat4 } from 'gl-matrix';
import type { TierResult } from 'detect-gpu';
import type vtkActor from '@kitware/vtk.js/Rendering/Core/Actor';
import type { vtkCamera } from '@kitware/vtk.js/Rendering/Core/Camera';
import vtkImageData from '@kitware/vtk.js/Common/DataModel/ImageData';
import vtkImageSlice from '@kitware/vtk.js/Rendering/Core/ImageSlice';
import type { vtkObject } from '@kitware/vtk.js/interfaces';
import vtkPlane from '@kitware/vtk.js/Common/DataModel/Plane';
import type vtkVolume from '@kitware/vtk.js/Rendering/Core/Volume';

// @public (undocumented)
Expand Down
9 changes: 8 additions & 1 deletion common/reviews/api/tools.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,13 @@ import type { TierResult } from 'detect-gpu';
import { vec3 } from 'gl-matrix';
import type vtkActor from '@kitware/vtk.js/Rendering/Core/Actor';
import vtkAnnotatedCubeActor from '@kitware/vtk.js/Rendering/Core/AnnotatedCubeActor';
import type { vtkCamera } from '@kitware/vtk.js/Rendering/Core/Camera';
import { vtkColorTransferFunction } from '@kitware/vtk.js/Rendering/Core/ColorTransferFunction';
import { vtkImageData } from '@kitware/vtk.js/Common/DataModel/ImageData';
import vtkImageSlice from '@kitware/vtk.js/Rendering/Core/ImageSlice';
import type { vtkObject } from '@kitware/vtk.js/interfaces';
import type { vtkPiecewiseFunction } from '@kitware/vtk.js/Common/DataModel/PiecewiseFunction';
import vtkPlane from '@kitware/vtk.js/Common/DataModel/Plane';
import vtkPolyData from '@kitware/vtk.js/Common/DataModel/PolyData';
import type vtkVolume from '@kitware/vtk.js/Rendering/Core/Volume';

Expand Down Expand Up @@ -2585,6 +2588,9 @@ function getCanvasEllipseCorners(ellipseCanvasPoints: CanvasCoordinates): Array<
// @public (undocumented)
function getChildAnnotations(annotation: Annotation): Annotation[];

// @public (undocumented)
function getClosestImageIdForStackViewport(viewport: StackViewport, worldPos: Types_2.Point3, viewPlaneNormal: Types_2.Point3): string;

// @public (undocumented)
function getClosestLineSegmentIntersection(points: Types_2.Point2[], p1: Types_2.Point2, q1: Types_2.Point2, closed?: boolean): {
segment: Types_2.Point2;
Expand Down Expand Up @@ -6119,7 +6125,8 @@ declare namespace utilities {
voi,
AnnotationFrameRange as annotationFrameRange,
contourSegmentation,
annotationHydration
annotationHydration,
getClosestImageIdForStackViewport
}
}
export { utilities }
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "1.74.1",
"version": "1.77.2",
"packages": [
"packages/adapters",
"packages/core",
Expand Down
Loading

0 comments on commit f736d84

Please sign in to comment.