int main()
{
itk::RandomPointSetSource<FloatPointSet2DType>::Pointer random;
random = itk::RandomPointSetSource<FloatPointSet2DType>::New();
random->SetMin(0.0);
random->SetMax(1000.0);
unsigned long size[2] = {20, 20};
random->SetSize(size);
float spacing[2] = {0.7, 2.1};
random->SetSpacing( spacing );
float origin[2] = {15, 400};
random->SetOrigin( origin );
typedef itk::ScalarToArrayCastPointSetFilter< FloatPointSet2DType,
ArrayPointSetType > CasterType;
CasterType::Pointer caster = CasterType::New();
caster->SetInput( random->GetOutput() );
caster->Update();
ArrayPointSetType > SampleType;
SampleType::Pointer sample = SampleType::New();
sample->SetPointSet( caster->GetOutput() );
return EXIT_SUCCESS;
}