Skip to main content

Flip Mask

The Flip Mask tool mirrors mask data along one or more axes. Unlike the Flip tool in the Image tab, which always flips every volume and mask in the project, this tool flips only the masks you select.

A shape on X and Y axes, the same shape mirrored along X by Flip, and the same shape with X and Y exchanged by Swap Axes

Accessing the Tool​

  1. Navigate to the Segmentation tab in the ribbon.
  2. Click Additional in the Operations section.
  3. Select Flip Mask from the dropdown menu.

Parameters​

Target Object(s)​

OptionDescription
Active maskFlip the active mask only.
Selected masksFlip all selected masks.
Visible masksFlip all visible masks.
All masksFlip every mask in the project.

Flip Axes​

Select the axes along which to flip the mask. The X, Y, and Z check boxes are independent, so you can combine them and apply the result in a single step.

AxisEffect
XMirrors across the YZ plane (Plane 1)
YMirrors across the XZ plane (Plane 2)
ZMirrors across the XY plane (Plane 3)

Selecting more than one axis mirrors along each selected axis in a single operation. For example, selecting X and Y gives the same result as flipping along X and then flipping along Y. At least one axis must be selected before applying.

Flip Reference​

OptionDescription
About originFlip using the coordinate system origin (0, 0, 0) as the mirror plane.
About centerFlip using the mask's geometric center as the mirror plane.

Workflow​

  1. Open the Flip Mask tool from the Segmentation tab.
  2. Select the Target Object(s).
  3. Select one or more axes to flip along (X, Y, Z).
  4. Choose the flip reference (About origin or About center).
  5. Click Apply to flip the masks.

Use Cases​

  • Correcting the orientation of an imported mask.
  • Creating a mirrored copy of an anatomical structure for left/right comparison.
  • Matching a mask to the orientation of another dataset.
warning

Flipping changes the spatial relationship between the mask and the underlying volume. Use the Flip tool in the Image tab if the volume must stay aligned with the mask.

Scripting​

This operation is available via the Python scripting API using flip().

import ScriptingApi as api

app = api.Application()
mask_operations = app.get_mask_operations()

# Flip along the X axis about the origin
mask_operations.flip(
["Mask1"],
True, # flip_x
False, # flip_y
False, # flip_z
True # about_origin: True=origin, False=center
)

# Flip along the X and Y axes about the center
mask_operations.flip(["Mask1"], True, True, False, False)

At least one axis must be selected, otherwise the call raises an error.

See the MaskOperations API Reference for details.

See Also​