clean1 = vtkCleanPolyData::New();
clean1->SetInputData( bbGetInputInPolyData() );
clean1->Update();
- printf("EED PolyDataToImageData::Process 1 \n");
vtkTriangleFilter *triangle1 = vtkTriangleFilter::New();
triangle1->SetInputData( clean1->GetOutput() );
triangle1->Update();
- printf("EED PolyDataToImageData::Process 2 \n");
// vtkPolyDataToImageStencil *dataToStencil = vtkPolyDataToImageStencil::New();
if (dataToStencil!=NULL) dataToStencil->Delete();
dataToStencil = vtkPolyDataToImageStencil::New();
dataToStencil->SetOutputSpacing( spc );
dataToStencil->SetOutputWholeExtent( ext );
dataToStencil->Update();
- printf("EED PolyDataToImageData::Process 3 \n");
// vtkExtractVOI *extract = vtkExtractVOI::New();
if (extract!=NULL) extract->Delete();
extract = vtkExtractVOI::New();
extract->SetInputData( bbGetInputInImage() );
extract->ReleaseDataFlagOff();
extract->Update();
- printf("EED PolyDataToImageData::Process 4 \n");
// vtkImageStencil *stencil = vtkImageStencil::New();
if (stencil!=NULL) stencil->Delete();
stencil = vtkImageStencil::New();
stencil->SetInputData( extract->GetOutput() );
stencil->Update();
- printf("EED PolyDataToImageData::Process 5 \n");
stencil->SetStencilData( dataToStencil->GetOutput() );
stencil->ReverseStencilOn();
stencil->SetBackgroundValue( bbGetInputBackgroundValue() );
stencil->Update();
- printf("EED PolyDataToImageData::Process 6 \n");
bbSetOutputOut( stencil->GetOutput() );
} else {
printf("EED Warnning! PolyDataToImageData::Process > Missing Image or PolyData inputs\n");