[vtkusers] Control VTK frame rate

kay jayavardhanravi at outlook.com
Tue Jul 4 16:26:37 EDT 2017


My Input data is generated by the realtime system, so the high frequency of
data. But the VTK application I am trying to build is not a real time
system. To explain further, the pseudo code that I posted before works by
calling render in a loop.

double realTimevariable; // This variable is updated by the real time system
every millisecond
while(true)
{
   t->Identity();
   t->RotateZ(realTimevariable); // realTimevariable takes the value at this
point of time
   t->update();  
   renderer->addActor(act);
   renderer->modified();
   renderWindow->render();
} 

Each time the loop is run value of the realTimeVariable is taken from the
memory at that instance of time.
This process works for less number of actors and frame rate is 12-14, but if
the actors are doubled the frame rate goes down by 7-9 which is visible to
the eye. From what I understand, this looping of render call
(renderWindow->Render();) is what you mentioned "swamping VTK with render
requests", Please correct me if I am wrong.

And I dont want to control data to 60 times per second, as I want VTK to
render as often as it can (Minimum of 12 FPS)

I am not using QT, just basic vtk pipeline in C++.



--
View this message in context: http://vtk.1045678.n5.nabble.com/Control-VTK-frame-rate-tp5743876p5743885.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list