00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
#ifndef __itkNeighborhoodInnerProduct_h
00018
#define __itkNeighborhoodInnerProduct_h
00019
00020
#include "itkNeighborhoodIterator.h"
00021
#include "itkNeighborhood.h"
00022
#include "itkConstSliceIterator.h"
00023
#include "itkImageBoundaryCondition.h"
00024
00025
namespace itk {
00026
00042
template<
class TImage,
class TOperator=ITK_TYPENAME TImage::PixelType,
class TComputation=TOperator>
00043 class ITK_EXPORT NeighborhoodInnerProduct
00044 {
00045
public:
00047 typedef NeighborhoodInnerProduct
Self;
00048
00050 typedef typename TImage::PixelType
ImagePixelType;
00051 typedef TOperator
OperatorPixelType;
00052 typedef TComputation
OutputPixelType;
00053
00055
itkStaticConstMacro(ImageDimension,
unsigned int, TImage::ImageDimension);
00056
00058
typedef Neighborhood<
OperatorPixelType,
00059 itkGetStaticConstMacro(ImageDimension)>
OperatorType;
00060
00061
typedef Neighborhood<
ImagePixelType,
00062 itkGetStaticConstMacro(ImageDimension)>
NeighborhoodType;
00063
00065
OutputPixelType operator()(
const std::slice &s,
00066
const ConstNeighborhoodIterator<TImage> &it,
00067
const OperatorType &op)
const;
00068 OutputPixelType operator()(
const ConstNeighborhoodIterator<TImage> &it,
00069
const OperatorType &op)
const
00070
{
00071
return this->operator()(std::slice(0, it.Size(), 1), it, op);
00072 }
00073
00074
00075 OutputPixelType operator()(
const std::slice &s,
00076
const NeighborhoodType &N,
00077
const OperatorType &op)
const;
00078
00079 OutputPixelType operator()(
const NeighborhoodType &N,
00080 const OperatorType &op)
const
00081
{
00082
return this->operator()(std::slice(0, N.Size(), 1), N, op);
00083 }
00084
00085
00086
00087 };
00088
00089
00090
00091
00092
00093 }
00094
00095
#ifndef ITK_MANUAL_INSTANTIATION
00096
#include "itkNeighborhoodInnerProduct.txx"
00097
#endif
00098
00099
#endif