[vtkusers] can't update contourFilter unless i do contourFilter->SetValue(, )

Sebastien Jourdain sebastien.jourdain at kitware.com
Mon Jun 14 07:55:28 EDT 2010


What I meant was not related to make an update call on all your
pipeline objects, because this is not required at all. If you do it on
the last object all the pipeline will be updated automatically if it
needed it.
Therefore, as I understand, after you changed the data, it does not
recompute the pipeline.
So it means, you didn't tell VTK that the data have changed....

You should call a methods like this.

vFrame->vol->Modified();
renWin->Render();

Seb


On Mon, Jun 14, 2010 at 4:50 AM, Liam Kurmos
<quantum.leaf at googlemail.com> wrote:
> Thank Seb,
>
> I am not observing this.
> The contourActor below is unmodified without the contourFilter->SetValue() call.
>
> my method is:
>
>               vFrame->reinitField();//after this the vtkImageData is modified
>
>              //try updating things
>               vFrame->vol->Update();
>               vFrame->contourFilter->Update();
>               vFrame->contourFilter->GetOutput()->Update();
>               vFrame->contourActor->GetMapper()->GetInput()->Update();
>
>               //remove works but add it back and it is not updated
>               vFrame->ren1->RemoveActor(vFrame->contourActor);
>               vFrame->ren1->AddActor(vFrame->contourActor);
>
>               //as a work around i can set the iso value to
> something else and then set it back.
>               vFrame->contourFilter->SetValue(0,newVal);
>               vFrame->contourFilter->SetValue(0,origVal)
>
>              renWin->Render();
>
> without the SetValue() call the vtkActor is not being updated. I have
> a work around for now, later today i will try to make a simple example
> of this and if it persits file a bug report.
>
> Liam
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



More information about the vtkusers mailing list