2D Transforms Now Supported in 3D Slicer

October 30, 2026

Registration of 2D images, such as histology sections, X-rays, or ultrasound frames, produces 2D transforms. Until recently, Slicer could not load them properly (as noted in issue #7633).

With our recent update 3D Slicer can now open 2D transforms. Implemented in PR #8842, this support allows 2D transforms to load like any other transform and can be applied to images, models, and markups.

How it works

Slicer’s world coordinate system is always 3D. A single-slice image is already extended to 3D when loaded, and we now take the same approach with 2D transforms, converting them to 3D as they are read. When applied to a 2D image, the converted transform deforms it exactly as the original 2D transform would in ITK’s resample filter.

For linear transforms, the 2×2 matrix is extended to 3×3. Scaling along the new third axis is the geometric mean of the other two scales, which minimizes geometric distortion. Its sign is chosen so the result is a right-handed coordinate system. Translation along the third axis is zero.

Slicer can now read 2D versions of every transform type it supports:

  • Linear (affine and its special cases)
  • Displacement fields
  • Thin plate splines
  • BSplines, including the legacy ITKv3 BSplineDeformableTransform

Each type is covered by the new vtkMRMLTransformStorageNodeTest3 test. Saving is unchanged: transforms are written as regular 3D transforms.

Try it

The feature is available in 3D Slicer 5.12. Drag and drop a 2D .tfm, .h5 or .mha transform into Slicer, then apply it in the Transforms module.

Slicer is open source, and all of its code is publicly available. The core of this work is in vtkITKTransformConverter.h. Questions and feedback are welcome on the Slicer forum.

Build the Slicer Capabilities Your Project Needs

Support for 2D transforms is one example of how Kitware extends Slicer’s capabilities. Need Slicer to support your data or add functionality your workflow requires?

Contact Kitware to discuss your Slicer development needs.

Leave a Reply