#include "__PLUGIN_NAME__ImageFilter.h"
#include <itkImageRegionIterator.h>


template<class TInput,class TOutput>
__PLUGIN_NAME__ImageFilter<TInput,TOutput>
::__PLUGIN_NAME__ImageFilter()
{
}


template<class TInput,class TOutput>
__PLUGIN_NAME__ImageFilter<TInput,TOutput>
::~__PLUGIN_NAME__ImageFilter()
{
}


//----------------------------------------------------------------------------
template<class TInput,class TOutput>
void
__PLUGIN_NAME__ImageFilter<TInput,TOutput>
::BeforeThreadedGenerateData()
{
}


//----------------------------------------------------------------------------
template<class TInput,class TOutput>
void
__PLUGIN_NAME__ImageFilter<TInput,TOutput>
::ThreadedGenerateData(const OutputImageRegionType& OutputRegionForThread,int threadId)
{
	OutputImageRegionType::IndexType OutputIndex = OutputRegionForThread.GetIndex();
	OutputImageRegionType::SizeType OutputSize = OutputRegionForThread.GetSize();

	// Here comes your filter code...
	// This example performs a 1:1 data copy
	
	typedef itk::ImageRegionConstIterator<InputImageType> InputIteratorType;
	InputIteratorType itIn(this->GetInput(),OutputRegionForThread);
	
	typedef itk::ImageRegionIterator<OutputImageType> OutputIteratorType;
	OutputIteratorType itOut(this->GetOutput(),OutputRegionForThread);
		
	for ( itOut.GoToBegin(),itIn.GoToBegin(); !itOut.IsAtEnd(); ++itOut,++itIn )
		itOut.Value() = itIn.Value();
}


//----------------------------------------------------------------------------
template<class TInput,class TOutput>
void
__PLUGIN_NAME__ImageFilter<TInput,TOutput>
::AfterThreadedGenerateData()
{
}






