ImageVolume
Hierarchy
- ImageVolume
Implements
Index
Constructors
Properties
Accessors
Methods
Constructors
constructor
Parameters
props: ImageVolumeProps
Returns ImageVolume
Properties
optionaladditionalDetails
Property to store additional information
cancelLoading
Type declaration
Returns void
dimensions
Dimensions of the volume
direction
volume direction in world space
hasPixelSpacing
whether the metadata for the pixel spacing is not undefined
imageCacheOffsetMap
optionalimageData
volume image data
isPreScaled
Whether preScaling has been performed on the volume
optionalloadStatus
load status object for the volume
metadata
volume metadata
numVoxels
volume number of voxels
origin
volume origin, Note this is an opinionated origin for the volume
optionalreferencedImageIds
optional reference image ids if the volume is derived from a set of images in the image cache
optionalreferencedVolumeId
optional reference volume id if the volume is derived from another volume
optionalscaling
volume scaling parameters if it contains scaled data
Type declaration
optionalPT?: { SUVbsaFactor?: number; SUVlbmFactor?: number; suvbwToSuvbsa?: number; suvbwToSuvlbm?: number }
optionalSUVbsaFactor?: number
optionalSUVlbmFactor?: number
optionalsuvbwToSuvbsa?: number
optionalsuvbwToSuvlbm?: number
optionalsizeInBytes
volume size in bytes
spacing
volume spacing in 3d world space
readonlyvolumeId
Read-only unique identifier for the volume
vtkOpenGLTexture
open gl texture for the volume
Accessors
publicimageIds
return the image ids for the volume if it is made of separated images
Returns string[]
updates the image ids
Parameters
newImageIds: string[]
Returns void
Methods
publicconvertToCornerstoneImage
Converts the requested imageId inside the volume to a cornerstoneImage object. It uses the typedArray set method to copy the pixelData from the correct offset in the scalarData to a new array for the image Duplicate of getCornerstoneImageLoadObject for legacy reasons
Parameters
imageId: string
the imageId of the image to be converted
imageIdIndex: number
the index of the imageId in the imageIds array
Returns IImageLoadObject
imageLoadObject containing the promise that resolves to the cornerstone image
publicconvertToImageSlicesAndCache
Converts all the volume images (imageIds) to cornerstoneImages and caches them. It iterates over all the imageIds and convert them until there is no enough space left inside the imageCache. Finally it will decache the Volume.
Returns string[]
publicdecache
If completelyRemove is true, remove the volume completely from the cache. Otherwise, convert the volume to cornerstone images (stack images) and store it in the cache
Parameters
completelyRemove: boolean = false
If true, the image will be removed from the cache completely.
Returns void | string[]
destroy
destroy the volume and make it unusable
Returns void
publicgetCornerstoneImage
Converts the requested imageId inside the volume to a cornerstoneImage object. It uses the typedArray set method to copy the pixelData from the correct offset in the scalarData to a new array for the image
Parameters
imageId: string
the imageId of the image to be converted
imageIdIndex: number
the index of the imageId in the imageIds array
Returns IImage
image object containing the pixel data, metadata, and other information
publicgetCornerstoneImageLoadObject
Converts the requested imageId inside the volume to a cornerstoneImage object. It uses the typedArray set method to copy the pixelData from the correct offset in the scalarData to a new array for the image
Parameters
imageId: string
the imageId of the image to be converted
imageIdIndex: number
the index of the imageId in the imageIds array
Returns IImageLoadObject
imageLoadObject containing the promise that resolves to the cornerstone image
publicgetCornerstoneImages
Returns an array of all the volume’s images as Cornerstone images. It iterates over all the imageIds and converts them to Cornerstone images.
Returns IImage[]
An array of Cornerstone images.
publicgetImageIdIndex
return the index of a given imageId
Parameters
imageId: string
imageId
Returns number
imageId index
publicgetImageURIIndex
return the index of a given imageURI
Parameters
imageURI: string
Returns number
imageURI index
publicgetScalarData
Return the scalar data for 3D volumes or the active scalar data (current time point) for 4D volumes
Returns PixelDataTypedArray
publicgetScalarDataArrays
Return all scalar data objects (buffers) which will be only one for 3D volumes and one per time point for 4D volumes images of each 3D volume is stored
Returns PixelDataTypedArray[]
scalar data array
publicgetScalarDataLength
Returns number
publicisDynamicVolume
return true if it is a 4D volume or false if it is 3D volume
Returns boolean
publicmodified
Updates the internals of the volume to reflect the changes in the underlying scalar data. This should be called when the scalar data is modified externally
Returns void
publicremoveFromCache
Returns void
The base class for volume data. It includes the volume metadata and the volume data along with the loading status.