vtkSMAnimationSceneWriter.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-License-Identifier: BSD-3-Clause
12 #ifndef vtkSMAnimationSceneWriter_h
13 #define vtkSMAnimationSceneWriter_h
14 
15 #include "vtkRemotingAnimationModule.h" //needed for exports
16 #include "vtkSMSessionObject.h"
17 
19 class vtkSMProxy;
20 
22 {
23 public:
25  void PrintSelf(ostream& os, vtkIndent indent) override;
26 
30  virtual void SetAnimationScene(vtkSMProxy*);
31 
33 
36  virtual void SetAnimationScene(vtkSMAnimationScene*);
37  vtkGetObjectMacro(AnimationScene, vtkSMAnimationScene);
39 
44  bool Save();
45 
47 
50  vtkSetStringMacro(FileName);
51  vtkGetStringMacro(FileName);
53 
55 
58  vtkSetMacro(StartFileCount, int);
59  vtkGetMacro(StartFileCount, int);
61 
63 
68  vtkSetVector2Macro(PlaybackTimeWindow, double);
69  vtkGetVector2Macro(PlaybackTimeWindow, double);
71 
73 
79  vtkSetMacro(Stride, int);
80  vtkGetMacro(Stride, int);
82 
83 protected:
85  ~vtkSMAnimationSceneWriter() override;
86 
87  unsigned long ObserverID;
89 
94  virtual bool SaveInitialize(int countStart) = 0;
95 
100  virtual bool SaveFrame(double time) = 0;
101 
106  virtual bool SaveFinalize() = 0;
107 
108  void ExecuteEvent(vtkObject* caller, unsigned long eventid, void* calldata);
109 
110  // Flag indicating if we are currently saving.
111  // Set on entering Save() and cleared before leaving Save().
112  bool Saving;
114  char* FileName;
115  double PlaybackTimeWindow[2];
117  int Stride = 1;
118 
119 private:
121  void operator=(const vtkSMAnimationSceneWriter&) = delete;
122 };
123 
124 #endif
superclass for any server manager classes that are related to a session
helper class used to write animations.
animation scene for ParaView.
vtkSMAnimationScene * AnimationScene
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
#define VTKREMOTINGANIMATION_EXPORT
void PrintSelf(ostream &os, vtkIndent indent) override