But, if I start to interact with the mouse on the “green line” (which is actually the “vtkImagePlaneWidget”) and moving it, the performances start to deteriorate very quickly and it could takes also 10 seconds to send the new image back to the client, as you can see in the following GIF:
As you can see in the gif, we collected three statistics:
-To Server (how many ms the client takes to reach the server)
-From Server (how many ms the server takes to return the image back to the client)
-Work Time (how many ms the server takes to render a new image)
What I can say is that:
the “Work Time” is always acceptable (lesser than 50ms)
but, in the last gif, the “To Server” and “From Server” time are really high
So I’m wondering:
We the performances are good while I’m rotating the model?
Why the same get worst when I start to move the 3d widge? (but please take in note that the “working time” remains acceptable).
Seems that there is a bug at the client side (ParaviewWeb) which prevents the frontend to receive the mouse input.
Have any idea how to investigate it?
Thanks and have a nice day
bye
Ennio
A more modern code base can be found here as well.
Yes we are looking into vtk.js as you suggest and apply the remote server as well.
Did you disable render on interaction on the VTK side?
To be honest I haven’t a clear picture about what a “Render On Interaction” is.
I need to look into that as well.
Is it implemented into VTK.JS?
Is there a documentation for this feature?
This is just that line so you don’t let the normal VTK flow trigger a render on mouse interaction. That way you can prevent some double render on the server side.
Hi thanks for the reply.
I sent you an email which contains the github repository.
At the end I will be happy to share the solution here on the forum (so also the community will have an idea).
regards,
Ennio Bolondi
PS: if the statistics present a negative number is because you should syncronize your system clock
Hi,
finally I made it!
At the end I was able to improve the Vtk.js performace by compiling vtkpython in release mode.
In that way the user interaction improved a lot.
I know this is not a real “solution”, it sounds more like a “work around”. But today I’m happy with it.
In debug mode the CPU consumption percentage was almost 100%, but now (in release) is less than 60% (so it wasn’t a “network”, but a “computation” issue).
Anyway, I will keep learning how the vtk event system works to find a better way to implement my solution.
I think the same “shortcut” will work fine in paraview as well.
Thanks and regards,
Ennio