Purpose

The module SetWorldMatrix copies the voxel-to-world-matrix from a reference image or composes anew matrix using elementary transforms.

Details

The world matrix of the output image is calculated by matrix-multiplication using the original matrix, the reference matrix and the elementary transform according to the selected status of the fields Source Image Matrix, Reference Image Matrix, and Elementary Transforms.

Finally the result is inverted on request:

RES = inv_or_id( ELM * REF * SRC )

where ELM, REF, and SRC are matrix, inverted matrix, or identity according to the settings of the usage-fields. If Set C-dimension info, Set T-dimension info, or Set U-dimension info are selected, information of the respective data dimension are forwarded from the reference image.

Windows

Default Panel

../../../Modules/ML/MLCoordUtils1/mhelp/Images/Screenshots/SetWorldMatrix._default.png

Input Fields

The module has two input images. Data from input0 are transfered to the output, input1 is used in calculating the new world-matrix if requested.

input0

name: input0, type: Image

Source image

input1

name: input1, type: Image

Reference image

Output Fields

output0

name: output0, type: Image

The module has one output. Data are copied from input0, the world-matrix is calculated according to selected parameters.

Parameter Fields

Visible Fields

Center for Scaling/Rotation

name: center, type: Vector3, default: 0 0 0

Sets a center for scaling.

Scale Orientation

name: scaleOrientation, type: Rotation, default: 0 0 1 0

Sets an orientation for scaling.

Scale

name: scale, type: Vector3, default: 1 1 1

Sets a scaling factor vector.

Rotation

name: rotation, type: Rotation, default: 0 0 1 0

Sets a rotation.

Translation

name: translation, type: Vector3, default: 0 0 0

Sets a translation.

Source Image Matrix

name: sourceUsage, type: Enum, default: Ignore, deprecated name: inputUsage

Defines how to use the source image’s matrix.

Values:

Title Name
Forward Forward
Inverse Inverse
Ignore Ignore

Reference Image Matrix

name: referenceUsage, type: Enum, default: Forward

Defines how to use the reference image’s matrix.

Values:

Title Name
Forward Forward
Inverse Inverse
Ignore Ignore

Elementary Transforms

name: elementaryUsage, type: Enum, default: Ignore

Defines how the elementary transformations should be used.

Values:

Title Name
Forward Forward
Inverse Inverse
Ignore Ignore

Invert result

name: invertResult, type: Bool, default: FALSE, deprecated name: invResult

If checked, the resulting transformation matrix is inverted.

Set C-dimension info

name: setCInfo, type: Bool, default: FALSE

If checked, the c-dimension info is copied from the reference image to the output image.

Set T-dimension info

name: setTInfo, type: Bool, default: FALSE

If checked, the t-dimension info is copied from the reference image to the output image.

Set U-dimension info

name: setUInfo, type: Bool, default: FALSE

If checked, the u-dimension info is copied from the reference image to the output image.