[Insight-users] Texture Feature Extraction

mohammed abdel samea mohammed_abdel_samea at yahoo.com
Wed May 12 04:13:22 EDT 2010


Hi,

I've tried to extract texture feature from an image. but wrote the following code:

typedef float InternalPixelType;
const unsigned int Dimension = 2;
typedef itk::Image< InternalPixelType, Dimension > InternalImageType;
typedef  itk::ImageFileReader< InternalImageType > ReaderType;
ReaderType::Pointer reader = ReaderType::New();
reader->SetFileName( FileName );

typedef itk::Statistics::ScalarImageToGreyLevelCooccurrenceMatrixGenerator<InternalImageType> GLCMGeneratorType;
typede fitk::Statistics::GreyLevelCooccurrenceMatrixTextureCoefficientsCalculator
<GLCMGeneratorType::HistogramType> TexCalcType;
InternalImageType::Pointer block = InternalImageType::New();
block->SetRegions(reader->GetOutput()->GetRequestedRegion());
block->Allocate();
GLCMGeneratorType::Pointer glcm = GLCMGeneratorType::New();
glcm->SetInput(block);
InternalImageType::OffsetType offset = {1,0};
glcm->SetOffset(offset);
glcm->SetNumberOfBinsPerAxis(256);
glcm->Compute();
TexCalcType::Pointer texCalc = TexCalcType::New();
texCalc->SetHistogram(glcm->GetOutput());
double contrast = texCalc->GetInertia();

But I've got errors: fatal error LNK1120: 12 unresolved externals. How can I solve this problem! help is really appreciated about that matter!. 

Best Regards,
 Mohammed


      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20100512/0f266df8/attachment-0001.htm>


More information about the Insight-users mailing list