Reputation: 413
I 've been trying to write a python script for paraview that rotates the camera. it looks like this:
from paraview.simple import *
paraview.simple._DisableFirstRenderCameraReset()
camera=GetActiveCamera()
# get animation scene
animationScene1 = GetAnimationScene()
#camera.Azimuth(45)
#Render()
camera.Elevation(45)
Render()
So while azimuth rotates the structure 45 degrees and 8 rotations bring it back to the original position, elevation is different.
It only takes 6 rotations and it is like the rotations 3 and 4 are skipped. It also gives a warning
Reseting view up since view plane normal is parallel
Any suggestions are much appreciated Thanks!
Upvotes: 0
Views: 264
Reputation: 413
As it turns out, if you add the command
camera.OrthogonalizeViewUp()
it prevents the warning and thus the orientation change of the camera
Upvotes: 1