/*========================================================================= Program: ShapeWorks: Particle-based Shape Correspondence & Visualization Module: $RCSfile: itkParticleNeighborhood.h,v $ Date: $Date: 2011/03/24 01:17:33 $ Version: $Revision: 1.2 $ Author: $Author: wmartin $ Copyright (c) 2009 Scientific Computing and Imaging Institute. See ShapeWorksLicense.txt for details. This software is distributed WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the above copyright notices for more information.=========================================================================*/#ifndef __itkParticleNeighborhood_h#define __itkParticleNeighborhood_h#include"itkDataObject.h"#include"itkPoint.h"#include"itkWeakPointer.h"#include"itkParticleDomain.h"#include"itkParticleContainer.h"#include"itkParticlePointIndexPair.h"#include<vector>namespaceitk{template<unsignedintVDimension=3>classITK_EXPORTParticleNeighborhood:publicDataObject{public:typedefParticleNeighborhoodSelf;typedefDataObjectSuperclass;typedefSmartPointer<Self>Pointer;typedefSmartPointer<constSelf>ConstPointer;typedefWeakPointer<constSelf>ConstWeakPointer;itkNewMacro(Self);itkTypeMacro(ParticleNeighborhood,DataObject);itkStaticConstMacro(Dimension,unsignedint,VDimension);typedefPoint<double,VDimension>PointType;typedefParticleDomainDomainType;typedefParticleContainer<PointType>PointContainerType;typedefstd::vector<ParticlePointIndexPair<VDimension>>PointVectorType;itkSetObjectMacro(PointContainer,PointContainerType);itkGetConstObjectMacro(PointContainer,PointContainerType);virtualPointVectorTypeFindNeighborhoodPoints(constPointType&,intidx,double)const{itkExceptionMacro("No algorithm for finding neighbors has been specified.");}virtualPointVectorTypeFindNeighborhoodPoints(constPointType&,intidx,std::vector<double>&,double)const{itkExceptionMacro("No algorithm for finding neighbors has been specified.");}virtualPointVectorTypeFindNeighborhoodPoints(constPointType&,intidx,std::vector<double>&,std::vector<double>&,double)const{itkExceptionMacro("No algorithm for finding neighbors has been specified.");}virtualunsignedintFindNeighborhoodPoints(constPointType&,intidx,double,PointVectorType&)const{itkExceptionMacro("No algorithm for finding neighbors has been specified.");return0;}itkSetObjectMacro(Domain,DomainType);itkGetConstObjectMacro(Domain,DomainType);virtualvoidAddPosition(constPointType&p,unsignedintidx,intthreadId=0){}virtualvoidSetPosition(constPointType&p,unsignedintidx,intthreadId=0){}virtualvoidRemovePosition(unsignedintidx,intthreadId=0){}protected:ParticleNeighborhood(){}voidPrintSelf(std::ostream&os,Indentindent)const{Superclass::PrintSelf(os,indent);}virtual~ParticleNeighborhood(){};private:ParticleNeighborhood(constSelf&);//purposely not implementedvoidoperator=(constSelf&);//purposely not implementedtypenamePointContainerType::Pointerm_PointContainer;typenameDomainType::Pointerm_Domain;};}// end namespace itk#if ITK_TEMPLATE_EXPLICIT//# include "Templates/itkParticleNeighborhood+-.h"#endif#if ITK_TEMPLATE_TXX//# include "itkParticleNeighborhood.txx"#endif#endif