pqCameraDialog.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-FileCopyrightText: Copyright (c) Sandia Corporation
3 // SPDX-License-Identifier: BSD-3-Clause
4 #ifndef pqCameraDialog_h
5 #define pqCameraDialog_h
6 
7 #include "pqDialog.h"
8 
9 class pqCameraDialogInternal;
10 class pqView;
12 class QDoubleSpinBox;
13 
14 class PQCOMPONENTS_EXPORT pqCameraDialog : public pqDialog
15 {
16  Q_OBJECT
17 public:
18  pqCameraDialog(QWidget* parent = nullptr, Qt::WindowFlags f = Qt::WindowFlags{});
19  ~pqCameraDialog() override;
20 
21  void SetCameraGroupsEnabled(bool enabled);
22 
26  static bool configureCustomViewpoints(QWidget* parentWidget, vtkSMRenderViewProxy* viewProxy);
27 
31  static bool addCurrentViewpointToCustomViewpoints(vtkSMRenderViewProxy* viewProxy);
32 
36  static bool applyCustomViewpoint(int CustomViewpointIndex, vtkSMRenderViewProxy* viewProxy);
37 
41  static bool deleteCustomViewpoint(int CustomViewpointIndex, vtkSMRenderViewProxy* viewProxy);
42 
46  static bool setToCurrentViewpoint(int CustomViewpointIndex, vtkSMRenderViewProxy* viewProxy);
47 
51  static QStringList CustomViewpointToolTips();
52 
56  static QStringList CustomViewpointConfigurations();
57 
58 public Q_SLOTS: // NOLINT(readability-redundant-access-specifiers)
59  void setRenderModule(pqView*);
60 
61 private Q_SLOTS:
62  // Description:
63  // Choose a file and load/save camera properties.
64  void saveCameraConfiguration();
65  void loadCameraConfiguration();
66 
67  // Description:
68  // Assign/restore the current camera properties to
69  // a custom view button.
70  void configureCustomViewpoints();
71  void applyCustomViewpoint();
72  void addCurrentViewpointToCustomViewpoints();
73  void updateCustomViewpointButtons();
74 
75  void resetViewDirectionPosX();
76  void resetViewDirectionNegX();
77  void resetViewDirectionPosY();
78  void resetViewDirectionNegY();
79  void resetViewDirectionPosZ();
80  void resetViewDirectionNegZ();
81 
82  void resetViewDirection(
83  double look_x, double look_y, double look_z, double up_x, double up_y, double up_z);
84 
85  void applyIsometricView();
86  void applyCameraRollPlus();
87  void applyCameraRollMinus();
88  void applyCameraElevationPlus();
89  void applyCameraElevationMinus();
90  void applyCameraAzimuthPlus();
91  void applyCameraAzimuthMinus();
92  void applyCameraZoomIn();
93  void applyCameraZoomOut();
94 
95  void resetRotationCenterWithCamera();
96 
97  void setInteractiveViewLinkOpacity(double value);
98  void setInteractiveViewLinkBackground(bool hideBackground);
99  void updateInteractiveViewLinkWidgets();
100 
101 protected:
102  void setupGUI();
103 
104 private:
105  pqCameraDialogInternal* Internal;
106 };
107 
108 #endif
This is a PQ abstraction of a generic view module.
Definition: pqView.h:26
implementation for View that includes render window and renderers.
enabled
value
This is a QDialog subclass that is aware of the undo-redo sub-system.
Definition: pqDialog.h:25