How can I get the real FPS from a remote rendering?

Hi,
I would like to know how can I get the real FPS from the image stream with a interactive ratio of 1 and interactive quality of 100. Because I was trying to capture from browser but I always get 60 fps, but clearly there is a drop of frames because of the quality and the amout of images transmitted.

Thanks.

It depends on how you get your FPS. If you ask for the server info (print in the bg), that will indeed be wrong. But the stream object of vtk.js does have that info, or at least you can gather that info and provide such information.

I usually take a window and provide a min/max/avg on that sampling window.

But that will depend on what client-side code you have access to or using.

I tried to follow this example vtk.js
But I having the same window for the remote rendering I get always 60 fps, no matter I change the interaction ratio and quality. But I see that there is a sort of lag during the streaming.
For local rendering, it works perfectly.

Ok so that window is only for local rendering which has no knowledge of the image stream.

I won’t have an easy solution, but you can look at that piece of code for the basic idea.

I was thinking on using ImageStream.OnImageReady with an interval that checks how many images arrive every second. Do you think this approach is valid?

It is a valid approach. I think you can even tap onto an other event that provide addition info such as the server time… Either way, this is the way to go.