[vtk-developers] xxxxxSPAMxxxxx Problem with vtkCutter

David Doria daviddoria+vtk at gmail.com
Thu Jan 7 07:52:17 EST 2010


On Thu, Jan 7, 2010 at 6:31 AM,  <twolanski at poczta.onet.pl> wrote:
> Dear All,
>
> I have a problem with vtkCutter. I don't know how to use vtkCutter with
> unstructed grid. I created below presented program :
>
> vtkPolyDataMapper *cutMapper=vtkPolyDataMapper::New();
> vtkStripper *cutStripper= vtkStripper::New(); vtkPolyDataNormals
> *cutpoly=vtkPolyDataNormals::New();
> cut = vtkCutter::New();
> cut->SetInput(ugrid);
> cut->SetValue(0,0.5);
> vtkActor *Acut = vtkActor::New();
> cutpoly->SetInput(cut->GetOutput());
> cutStripper->SetInput(cutpoly->GetOutput());
> cutMapper->SetInput(cutStripper->GetOutput());
> Acut->SetMapper(cutMapper);
> vtkWindow1->GetRenderer()->AddActor(Acut);
> vtkWindow1->Invalidate();
>
> but I cannot see any change in my object.
>
> Could somebody be so kind to point out what's wrong with my code?
>
> I would be very grateful for any suggestion what I should modify or check.
>
> Thanks in advance and
> Best regards
>
> Tomasz

Tomasz,

This is certainly a discussion for the VTK users list, not the
developers list. Let's please continue the conversation there.

I don't see any Update() calls in there. Maybe they are not necessary?
Have you played with this example?
http://www.cmake.org/Wiki/VTK_Examples_vtkCutter

Thanks,

David



More information about the vtk-developers mailing list