Bug in vtkImageReslice ... (VTK 5.0)

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Bug in vtkImageReslice ... (VTK 5.0)

Vincent Nicolas-2
Hi all,

While upgrading my code to VTK 5.0 (the version released on the website), I've found what seems to be a bug in vtkImageReslice. I'm applying transformation on an Image using vtkImageReslice, and then extracting a contour, using vtkMarchingSquares (on 1 slice), which is transformed before visualized. This pipe were working fine with VTK 4.4, but no more with VTK 5.0. No contour is created by the contour filter. Although, the output of vtkImageReslice can be visualized, and seems to be correct (origin, size, pixels, ...). No error is reported in the console during the execution.
I also tried using a vtkExtractVOI filter to extract only one slice, but the save problem happends.

I've the same behaviour on Windows and Linux.

Here is the code that was working on 4.0 and not on 5.0 (without any modifications) :

vtkImageReslice* reslice = vtkImageReslice::New();
reslice->SetInput(reader->GetOutput());
// reslice->UpdateWholeExtent(); no effect on this bug
                       
this->contour = vtkMarchingSquares::New();
this->contour->SetInput(reslice->GetOutput());
this->contour->SetImageRange(dim[0],dim[1],dim[2],dim[3],z,z);
this->contour->SetValue(0,300);
this->contour->Update();

this->vtkTrans = vtkTransform::New();
this->vtkTrans->Identity();
this->vtkTransFilter = vtkTransformPolyDataFilter::New();
this->vtkTransFilter->SetTransform(this->vtkTrans);
this->vtkTransFilter->SetInput(this->contour->GetOutput());
this->mapper = vtkPolyDataMapper2D::New();
this->mapper->ScalarVisibilityOff();
this->actor = vtkActor2D::New();


Does anyone has an idea where the bug is or how to resolve it ?

Thanks,

Vincent NICOLAS
-----------------------------------------
Communications and Remote Sensing Lab.
Universite catholique de Louvain
[hidden email]
+32 (0)10 478555
http://www.tele.ucl.ac.be
_______________________________________________
This is the private VTK discussion list.
Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers