pqAnimationScene.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 pqAnimationScene_h
5 #define pqAnimationScene_h
6 
7 #include "pqProxy.h"
8 #include <QPair>
9 #include <QSet>
10 
12 class pqAnimationCue;
13 class QSize;
14 class vtkObject;
15 
22 {
23  Q_OBJECT
24  typedef pqProxy Superclass;
25 
26 public:
27  pqAnimationScene(const QString& group, const QString& name, vtkSMProxy* proxy, pqServer* server,
28  QObject* parent = nullptr);
29  ~pqAnimationScene() override;
30 
36  pqAnimationCue* getCue(vtkSMProxy* proxy, const char* propertyname, int index) const;
37 
39 
45  pqAnimationCue* createCue(vtkSMProxy* proxy, const char* propertyname, int index);
46  pqAnimationCue* createCue(
47  vtkSMProxy* proxy, const char* propertyname, int index, const QString& cuetype);
48  pqAnimationCue* createCue(const QString& cuetype);
49  pqAnimationCue* createCue(const pqAnimatedPropertyInfo& propInfo);
51 
55  void removeCues(vtkSMProxy* proxy);
56 
60  void removeCue(pqAnimationCue* cue);
61 
65  bool contains(pqAnimationCue*) const;
66 
70  QPair<double, double> getClockTimeRange() const;
71 
75  QSet<pqAnimationCue*> getCues() const;
76 
80  double getAnimationTime() const;
81 
85  QList<double> getTimeSteps() const;
86 
87 Q_SIGNALS:
91  void preAddedCue(pqAnimationCue*);
92 
96  void addedCue(pqAnimationCue*);
97 
101  void preRemovedCue(pqAnimationCue*);
102 
106  void removedCue(pqAnimationCue*);
107 
111  void cuesChanged();
112 
116  void playModeChanged();
117 
122  void loopChanged();
123 
127  void clockTimeRangesChanged();
128 
134  void beginPlay(vtkObject* caller, unsigned long, void*, void* reversed);
135 
141  void endPlay(vtkObject* caller, unsigned long, void*, void* reversed);
142 
147  void tick(int percentCompleted);
148 
153  void animationTime(double time);
154 
158  void frameCountChanged();
159 
163  void timeStepsChanged();
164 
168  void timeLabelChanged();
169 
170 public Q_SLOTS:
174  void play();
175 
179  void pause();
180 
184  void setAnimationTime(double time);
185 
186 private Q_SLOTS:
192  void onCuesChanged();
193 
197  void onTick(vtkObject* caller, unsigned long, void*, void* info);
198 
203  void onAnimationTimePropertyChanged();
204 
205 protected:
209  void initializeCue(vtkSMProxy* proxy, const char* propertyname, int index, pqAnimationCue* cue);
210 
211 private:
212  Q_DISABLE_COPY(pqAnimationScene)
213 
214  class pqInternals;
215  pqInternals* Internals;
216 
217  pqAnimationCue* createCueInternal(
218  const QString& cuetype, vtkSMProxy* proxy, const char* propertyname, int index);
219 };
220 
221 #endif
info
pqAnimationCue is the pqProxy wrapping an animation proxy.
name
time
#define PQCORE_EXPORT
Definition: pqCoreModule.h:15
This class represents any registered Server Manager proxy.
Definition: pqProxy.h:28
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
pqAnimatedPropertyInfo stores information about an animated property.
index
pqAnimationScene is a representation for a vtkSMAnimationScene proxy.
pqServer (should be renamed to pqSession) is a pqServerManagerModelItem subclass that represents a vt...
Definition: pqServer.h:35