#include "itksys/SystemTools.hxx"
#ifdef ENABLE_QUICKVIEW
#endif
static void
int
main(int argc, char * argv[])
{
std::string inputFilename;
if (argc < 2)
{
CreateImage(image);
inputFilename = "Synthetic";
}
else
{
image = itk::ReadImage<ImageType>(argv[1]);
inputFilename = argv[1];
}
PixelType pixel;
pixel.SetRed(255);
pixel.SetGreen(127);
pixel.SetBlue(50);
corner2[0] = corner1[0] + region.GetSize()[0] - 1;
corner2[1] = corner1[1] + region.GetSize()[1] - 1;
it1.GoToBegin();
while (!it1.IsAtEnd())
{
it1.Set(pixel);
++it1;
}
#ifdef ENABLE_QUICKVIEW
if (argc > 1)
{
viewer.
AddImage<ImageType>(image,
true, itksys::SystemTools::GetFilenameName(argv[1]));
}
else
{
viewer.
AddImage<ImageType>(image,
true,
"Synthetic");
}
#endif
return EXIT_SUCCESS;
}
void
{
auto regionSize = ImageType::SizeType::Filled(100);
region.SetIndex(regionIndex);
PixelType pixel;
pixel.SetRed(0);
pixel.SetGreen(127);
pixel.SetBlue(200);
image->SetRegions(region);
image->Allocate();
image->FillBuffer(pixel);
}