How can I change the center of rotation for mouse interaction?

Hello, I’m currently using ‘paraviewweb/src/NativeUI/Canvas/RemoteRenderer’ from paraviewweb@3.2.13

I found out that if I drag the viewer with holding shift, I can move view with translation.
However, the center of rotation remains with (0, 0, 0) I think.

Can I change the center of rotation to the center of the current camera view?
Or should I modify or add new methods to handle this?

Thank you :slight_smile:

You can use the Pick Center of Rotation button pqPickCenter. It is located in the middle toolbar all the way to the right. Once you click that, you can click somewhere in the 3D view to change the center of rotation to that part of the geometry.

If you want to specify a specific coordinate, you can use the Adjust Camera button pqEditCamera. This is located in that thin toolbar right above the 3D view (5th from the left). When you click that, you get a dialog box that allows you to specify a center of rotation.

Thanks for your reply but my problem was about using paraviewweb remote renderer.

Can I get some API information for selecting center of the rotation?

@jourdain

You will indeed need to create a new method on the server to use your current focal point as center of rotation. Such method could be done automatically on your app or via a button click.

@exportRpc('reset.center')
def resetCenter(self):
   view = simple.GetRenderView()
   view.CenterOfRotation = view.CameraFocalPoint
1 Like