Skip to content

Improve python trace in camera dialog

  • This is a follow up MR for !5615 (merged) and !5595 (merged)
  • The trace includes named function calls for each camera adjustment.
  • AdjustAzimuth, AdjustElevation, AdjustRoll, AdjustZoom are used to make adjustments.
  • Previously, the trace looked like
#!/bin/env python3
AdjustCamera(0, 90.0)
AdjustCamera(3, 1.5)
AdjustCamera(1, 4.0)
AdjustCamera(2, -30.0)
AdjustCamera(3, 0.666666)
AdjustCamera(1, -60.0)

To find out the meaning of those integer parameters (0,1,2,3) , you had to explore the enumerations in vtkSMRenderViewProxy

  • Now, it is concise.
#!/bin/env python3
AdjustRoll(90.0)
AdjustZoom(1.5)
AdjustElevation(4.0)
AdjustAzimuth(-30.0)
AdjustZoom(0.666666)
AdjustRoll(-60.0)
  • Some minor fixes/additions for camera dialog.
    • Remove dead code from pqCameraDialog
    • Include the new isometric view button in the camera dialog.
    • Remove call to resetCamera in pqRenderView::adjustView. This method was added in !5615 (merged). An adjustment was never meant to reset the camera to data bounds.
Edited by Jaswant Panchumarti (Kitware)

Merge request reports