Skip to main content

Interface: ViewReference

A view reference references the image/location of an image. Typical use cases include remembering the current position of a viewport to allow returning to it later, as well as determining whether specific views should show annotations or other overlay information.

Note this is an interface as it is designed to allow extension/customization by additional Viewport modules.

Properties

bounds?

optional bounds: BoundsLPS

The bounds that are shown. Allows specifying whether a view includes particular bounds or not. This will be in world coordinates.

Defined in

packages/core/src/types/IViewport.ts:270


cameraFocalPoint?

optional cameraFocalPoint: Point3

The focal point of the camera in world space. The focal point is used for to define the stack positioning, but not the zoom/pan (which is defined by the view presentation object.)

Single point objects (probe etc) should use the probe point as the camera focal point as that allows omitting the view plane normal and showing the probe in any orientation.

Defined in

packages/core/src/types/IViewport.ts:225


FrameOfReferenceUID?

optional FrameOfReferenceUID: string

The FrameOfReferenceUID

Defined in

packages/core/src/types/IViewport.ts:167


multiSliceReference?

optional multiSliceReference: ReferencedImageRange

The multi-slice selection is some sort of specifier for additional view references which extend this selection to additional slices. The only allowed current value is the referenced image range, to select a range of slices, but the intent is to allow other types of references to be included in the future.

Defined in

packages/core/src/types/IViewport.ts:213


planeRestriction?

optional planeRestriction: PlaneRestriction

A referenced plane identifies one or more planes. Currently this has a point within the plane to identify the focal depth (but NOT the focal point), and up to two coplanar vectors.

The referenced plane is visible depth wise if the point minus the focal point of hte current view is orthogonal to the view plane normal of the viewport. This is sufficient for a single-point identifier. For a line, the inPlaneVector must be orthogonal to the view plane normal of the viewport. For a planar annotation, both inPlaneVectors must be orthogonal to the view plane normal of the viewport.

This extension from the least specific to the most specific types of views allows determining whether a view can be seen in a variety of conditions. It does not allow recovering the original view reference.

Defined in

packages/core/src/types/IViewport.ts:184


referencedImageId?

optional referencedImageId: string

An optional property used to specify the particular image that this view includes. For volumes, that will specify which image is closest to the requested point(s) in some fashion, or will be undefined when the reference applies to any volume with the same frame of reference.

The naming of this particular attribute matches the DICOM SR naming for the referenced image, as well as historical naming in CS3D.

For range/selection, this must be the starting range referenced image id

Defined in

packages/core/src/types/IViewport.ts:197


referencedImageURI?

optional referencedImageURI: string

This is an internal copy of referencedImageId without the volume loader specification included. It is used for equality and fast lookup checks to find whether and how this view reference can be displayed on a viewport.

Defined in

packages/core/src/types/IViewport.ts:204


sliceIndex?

optional sliceIndex: number

This value is primarily an informational slice index as it isn't a reliable way to navigate to a specified slice. HOwever, if it is the only value provided, then it can be used to navigate to a specific slice index. As well, it can be used as informational display information.

The slice index for the image of interest NOTE The slice index is relative to the volume or video image. You cannot apply a slice index from one volume or stack to another as they do NOT apply. The referencedImageId should belong to the volume you are trying to apply to, the viewPlane normal should be identical, and then you can apply the sliceIndex.

WarningThe slice index is not deterministic between different sets of images containing the same image id. It is intended more as information useful for display about a given view reference with a given context. The intent is to move this to the statistics data to specify the stats for a given slice object.

Defined in

packages/core/src/types/IViewport.ts:260


viewPlaneNormal?

optional viewPlaneNormal: Point3

The normal for the current view. This defines the plane used to show the 2d annotation. This should be omitted if the annotation is a point to allows for single-point annotations.

Defined in

packages/core/src/types/IViewport.ts:232


viewUp?

optional viewUp: Point3

The view up - this is only used for resetting orientation

Defined in

packages/core/src/types/IViewport.ts:237


volumeId?

optional volumeId: string

VolumeId that the referencedImageId was chosen from

Defined in

packages/core/src/types/IViewport.ts:265