Skip to content

Commit

Permalink
ENH: Add TileMergeImageFilter wrapping
Browse files Browse the repository at this point in the history
  • Loading branch information
thewtex committed Jan 13, 2020
1 parent c65afee commit e7da790
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion include/itkTileMergeImageFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ class ITK_TEMPLATE_EXPORT TileMergeImageFilter
* To be called for each tile position in the mosaic
* before the call to Update(). */
void
SetTileTransform(TileIndexType position, TransformConstPointer transform);
SetTileTransform(TileIndexType position, const TransformType * transform);

/** Get/Set background value (used if CropToFill is false).
* Default PixelType's value (usually zero) if not set. */
Expand Down
6 changes: 3 additions & 3 deletions include/itkTileMergeImageFilter.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ TileMergeImageFilter<TImageType, TPixelAccumulateType, TInterpolator>::SetMontag
{
m_Montage = montage;
this->SetMontageSize(montage->m_MontageSize);
this->m_FinishedPairs = montage->m_FinishedPairs;
this->m_FinishedPairs.store(montage->m_FinishedPairs);
this->m_OriginAdjustment = montage->m_OriginAdjustment;
this->m_ForcedSpacing = montage->m_ForcedSpacing;

Expand Down Expand Up @@ -136,7 +136,7 @@ TileMergeImageFilter<TImageType, TPixelAccumulateType, TInterpolator>::SetMontag
template <typename TImageType, typename TPixelAccumulateType, typename TInterpolator>
void
TileMergeImageFilter<TImageType, TPixelAccumulateType, TInterpolator>::SetTileTransform(TileIndexType position,
TransformConstPointer transform)
const TransformType * transform)
{
SizeValueType linInd = this->nDIndexToLinearIndex(position);
if (m_Transforms[linInd].IsNull() || m_Transforms[linInd]->GetParameters() != transform->GetParameters() ||
Expand Down Expand Up @@ -468,7 +468,7 @@ TileMergeImageFilter<TImageType, TPixelAccumulateType, TInterpolator>::ResampleS
bool interpolate = false;
if (m_Montage.IsNotNull()) // we can check whether interpolation was used
{
const auto InterpolationNone = Superclass::PCMOptimizerType::PeakInterpolationMethod::None;
const auto InterpolationNone = Superclass::PCMOptimizerType::PeakInterpolationMethodEnum::None;
interpolate = (m_Montage->GetPeakInterpolationMethod() != InterpolationNone);
}
else // examine alignment of image grids of all the contributing regions
Expand Down
2 changes: 2 additions & 0 deletions wrapping/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ set(WRAPPER_SUBMODULE_ORDER
itkPhaseCorrelationOptimizer
itkPhaseCorrelationImageRegistrationMethod
itkMaxPhaseCorrelationOptimizer
itkTileConfiguration
itkTileMontage
)
itk_auto_load_submodules()
itk_end_wrap_module()
7 changes: 7 additions & 0 deletions wrapping/itkTileMergeImageFilter.wrap
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
itk_wrap_class("itk::TileMergeImageFilter" POINTER)
foreach(d ${ITK_WRAP_IMAGE_DIMS})
foreach(t ${WRAP_ITK_SCALAR})
itk_wrap_template("${ITKM_I${t}${d}}${ITKM_D}" "${ITKT_I${t}${d}},${ITKT_D}")
endforeach()
endforeach()
itk_end_wrap_class()

0 comments on commit e7da790

Please sign in to comment.