ITK  4.8.0
Insight Segmentation and Registration Toolkit
SphinxExamples/src/Core/Common/ConceptCheckingIsSameDimension/Code.cxx
#include "itkImage.h"
template< typename TImage, unsigned int VDimension >
void CheckIfDimensionIsTheSame( const TImage* const )
{
}
int main( int, char* [] )
{
const unsigned int Dimension = 2;
typedef unsigned char PixelType;
ImageType::Pointer image = ImageType::New();
CheckIfDimensionIsTheSame< ImageType, 2 >( image.GetPointer() );
CheckIfDimensionIsTheSame< ImageType, ImageType2::ImageDimension >( image.GetPointer() );
return EXIT_SUCCESS;
}