// itk
#include <itkBoundingBox.h>
#include <itkJoinSeriesImageFilter.h>
+#include <itkChangeInformationImageFilter.h>
/*
According to
template<class ImageType>
typename ImageType::Pointer
AutoCrop(const ImageType * input,
- typename ImageType::PixelType BG) {
+ typename ImageType::PixelType BG,
+ const bool useBorderFlag=false) {
typedef clitk::AutoCropFilter<ImageType> AutoCropFilterType;
typename AutoCropFilterType::Pointer autoCropFilter = AutoCropFilterType::New();
autoCropFilter->SetInput(input);
autoCropFilter->SetBackgroundValue(BG);
+ autoCropFilter->SetUseBorder(useBorderFlag);
autoCropFilter->Update();
return autoCropFilter->GetOutput();
}
double spacing=-1,
bool autocropflag=true,
bool singleObjectCCL=true);
+ template<class MaskImageType>
+ typename MaskImageType::Pointer
+ SliceBySliceRelativePosition(const MaskImageType * input,
+ const MaskImageType * object,
+ int direction,
+ double threshold,
+ double angle,
+ bool inverseflag,
+ bool uniqueConnectedComponent=false,
+ double spacing=-1,
+ bool autocropflag=true,
+ bool singleObjectCCL=true);
//--------------------------------------------------------------------
// In a binary image, search for the point belonging to the FG that
std::vector<typename ImageType::PointType> & lB,
typename ImageType::PixelType BG,
int mainDirection,
- double offsetToKeep);
+ double offsetToKeep,
+ bool keepIfEqual=false);
+ template<class ImageType>
+ void
+ SliceBySliceSetBackgroundFromLineSeparation_pt(ImageType * input,
+ std::vector<typename ImageType::PointType> & lA,
+ std::vector<typename ImageType::PointType> & lB,
+ typename ImageType::PixelType BG,
+ typename ImageType::PointType offsetToKeep,
+ bool keepIfEqual=false);
//--------------------------------------------------------------------
typename ImageType::PixelType & BG);
//--------------------------------------------------------------------
-
+ //--------------------------------------------------------------------
+ template<class ImageType>
+ typename ImageType::Pointer
+ RemoveNegativeIndexFromRegion(ImageType * input);
+ //--------------------------------------------------------------------
+
} // end clitk namespace