[vtkusers] R: moving camera and updating the rendering

Lazzarato Dr.Gianni lazzadrgi at libero.it
Fri Mar 12 08:22:09 EST 2010


Hi Giancarlo, 

                        you need to call :     mp_VTKwidget->update();

 

Gianni Lazzarato

 

 

Da: vtkusers-bounces at vtk.org [mailto:vtkusers-bounces at vtk.org] Per conto di
Giancarlo Amati
Inviato: venerdì 12 marzo 2010 14.15
A: vtkusers at vtk.org
Oggetto: [vtkusers] moving camera and updating the rendering

 

Hello vtkUsers,

I'm back with, I'm sure, a "so-many-times-asked" question:

I've a camera and a file with a sequence of postions that the camera takes.
Now, I'm using the QVTKWidget for rendering my scene.

I call:

vtkSmartPointer<vtkCamera>tmpCam =
this->mp_VTKwidget->GetRenderWindow()->GetRenderers()->GetFirstRenderer()->G
etActiveCamera();
        tmpCam->SetViewUp((*mI_vtkCamera)->GetViewUp());
        tmpCam->SetPosition((*mI_vtkCamera)->GetPosition());
        tmpCam->SetFocalPoint((*mI_vtkCamera)->GetFocalPoint());

to update the current renderer camera position.
But What I'm not seeing is an update of the view untile I click with the
mouse inside the QVTKWidget (mp_VTKwidget).
so my question is HOW to update/refresh the view automatically?

I tried the method Render() of the vtkRenderer but it's apparently
unseccessful.

Many thanks.
Giancarlo

  _____  

Lo spazio su Hotmail aumente con le tue esigenze... Vai
<http://www.windowslive.it/hotmail/SpazioDisponibile.aspx>  oltre i 5GB

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100312/e4d0928f/attachment.htm>


More information about the vtkusers mailing list