pqAnimationCue.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 pqAnimationCue_h
5 #define pqAnimationCue_h
6 
7 #include "pqProxy.h"
8 
9 #include "vtkSmartPointer.h"
10 
11 class vtkSMProxy;
12 class vtkSMProperty;
13 
18 {
20  QString Name = QString();
21  int Index = 0;
22 };
23 
35 class PQCORE_EXPORT pqAnimationCue : public pqProxy
36 {
37  Q_OBJECT
38  typedef pqProxy Superclass;
39 
40 public:
41  pqAnimationCue(const QString& group, const QString& name, vtkSMProxy* proxy, pqServer* server,
42  QObject* parent = nullptr);
43  ~pqAnimationCue() override;
44 
48  int getNumberOfKeyFrames() const;
49 
53  QList<vtkSMProxy*> getKeyFrames() const;
54 
62  vtkSMProxy* insertKeyFrame(int index);
63 
68  void deleteKeyFrame(int index);
69 
73  vtkSMProxy* getKeyFrame(int index) const;
74 
78  vtkSMProxy* getAnimatedProxy() const;
79 
83  vtkSMProperty* getAnimatedProperty() const;
84 
88  QString getAnimatedPropertyName() const;
89 
93  static QString getCameraModeName(int mode);
94 
98  int getAnimatedPropertyIndex() const;
99 
104  void setKeyFrameType(const QString& type) { this->KeyFrameType = type; }
105 
110  void triggerKeyFramesModified() { Q_EMIT this->keyframesModified(); }
111 
113 
116  void setEnabled(bool enable);
117  bool isEnabled() const;
119 
123  QString getDisplayName();
124 
128  bool isCameraCue();
129 
133  bool isPythonCue();
134 
138  bool isTimekeeperCue();
139 
140 Q_SIGNALS:
144  void keyframesModified();
145 
149  void modified();
150 
154  void enabled(bool);
155 
156 private Q_SLOTS:
160  void onEnabledModified();
161 
162 private: // NOLINT(readability-redundant-access-specifiers)
163  Q_DISABLE_COPY(pqAnimationCue)
164 
165 
166 
169  void addKeyFrameInternal(vtkSMProxy*);
170  void removeKeyFrameInternal(vtkSMProxy*);
171  QString KeyFrameType;
173 };
174 #endif
pqAnimatedPropertyInfo
pqAnimatedPropertyInfo stores information about an animated property.
Definition: pqAnimationCue.h:17
pqAnimatedPropertyInfo::Proxy
vtkSmartPointer< vtkSMProxy > Proxy
Definition: pqAnimationCue.h:19
type
type
pqAnimatedPropertyInfo::Name
QString Name
Definition: pqAnimationCue.h:20
pqAnimationCue::setKeyFrameType
void setKeyFrameType(const QString &type)
Set the type of the keyframe created by default.
Definition: pqAnimationCue.h:104
vtkSmartPointer< vtkSMProxy >
vtkSMProperty
superclass for all SM properties
Definition: vtkSMProperty.h:144
vtkSMProxy
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
pqAnimatedPropertyInfo::Index
int Index
Definition: pqAnimationCue.h:21
pqServer
pqServer (should be renamed to pqSession) is a pqServerManagerModelItem subclass that represents a vt...
Definition: pqServer.h:35
vtkSmartPointer.h
enabled
enabled
name
name
pqAnimationCue::triggerKeyFramesModified
void triggerKeyFramesModified()
Used by editors to trigger keyframesModified() signal after bulk of modifications have been made to t...
Definition: pqAnimationCue.h:110
pqProxy
This class represents any registered Server Manager proxy.
Definition: pqProxy.h:28
mode
mode
pqAnimationCue
pqAnimationCue is the pqProxy wrapping an animation proxy.
Definition: pqAnimationCue.h:35
pqProxy.h
index
index