Function: calculateViewportsSpatialRegistration()
calculateViewportsSpatialRegistration(
viewport1
,viewport2
):void
It calculates the registration matrix between two viewports (currently only translation is supported) If the viewports are in the same frame of reference, it will return early, but otherwise it will use the current image's metadata to calculate the translation between the two viewports and adds it to the spatialRegistrationModule metadata provider
Parameters
• viewport1: IStackViewport
| VolumeViewport
The first stack viewport
• viewport2: IStackViewport
| VolumeViewport
The second stack viewport
Returns
void
Defined in
packages/core/src/utilities/calculateViewportsSpatialRegistration.ts:26