Helper class for setting MITK images as masks on MatchPoint registration algorithms.
More...
#include <mitkMaskedAlgorithmHelper.h>
Helper class for setting MITK images as masks on MatchPoint registration algorithms.
MaskedAlgorithmHelper bridges MITK mask images to the MatchPoint MaskedRegistrationAlgorithm interface. Mask pixels with values != 0 are treated as inside the mask region.
- Note
- Currently only 2D-2D and 3D-3D algorithms are supported.
-
Current implementation is not thread-safe. Use one helper instance per registration task.
- See also
- mitk::MAPAlgorithmHelper
Definition at line 41 of file mitkMaskedAlgorithmHelper.h.
◆ MaskedAlgorithmHelper()
| mitk::MaskedAlgorithmHelper::MaskedAlgorithmHelper |
( |
map::algorithm::RegistrationAlgorithmBase * |
algorithm | ) |
|
Constructs a helper for the given registration algorithm.
- Parameters
-
| [in] | algorithm | Pointer to the MatchPoint registration algorithm that should receive masks. |
◆ ~MaskedAlgorithmHelper()
| mitk::MaskedAlgorithmHelper::~MaskedAlgorithmHelper |
( |
| ) |
|
|
inline |
◆ CheckSupport()
| bool mitk::MaskedAlgorithmHelper::CheckSupport |
( |
const mitk::Image * |
movingMask, |
|
|
const mitk::Image * |
targetMask |
|
) |
| const |
Checks whether the algorithm supports masks of the given types.
- Parameters
-
| [in] | movingMask | Pointer to the moving mask image to check compatibility for. |
| [in] | targetMask | Pointer to the target mask image to check compatibility for. |
- Returns
- True if the algorithm supports the given mask types, false otherwise.
◆ HasMaskedRegistrationAlgorithmInterface()
| static bool mitk::MaskedAlgorithmHelper::HasMaskedRegistrationAlgorithmInterface |
( |
const map::algorithm::RegistrationAlgorithmBase * |
algorithm | ) |
|
|
static |
Checks whether the given algorithm implements the MaskedRegistrationAlgorithm interface.
- Parameters
-
| [in] | algorithm | Pointer to the algorithm to check. |
- Returns
- True if the algorithm supports masks, false otherwise.
◆ SetMasks()
Sets one or both masks on the algorithm.
If the algorithm does not support the masked registration interface, the masks are ignored. The mask images are converted to spatial objects internally.
- Parameters
-
| [in] | movingMask | Pointer to the mask image for the moving data, or nullptr to skip. |
| [in] | targetMask | Pointer to the mask image for the target data, or nullptr to skip. |
- Returns
- True if the masks were successfully set (algorithm supports masks), false otherwise.
The documentation for this class was generated from the following file: