HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HOM_playbar.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * COMMENTS:
7  */
8 
9 #ifndef __HOM_playbar_h__
10 #define __HOM_playbar_h__
11 
12 #include "HOM_API.h"
13 #include "HOM_Defines.h"
14 
15 #include <map>
16 #include <string>
17 #include <vector>
18 
19 class HOM_BaseKeyframe;
20 class HOM_Bookmark;
21 class HOM_ChannelList;
22 template <typename T> class HOM_ElemPtr;
23 class HOM_EnumValue;
24 class HOM_Node;
25 class HOM_Pane;
26 class HOM_Parm;
27 class HOM_ParmTuple;
28 class HOM_Vector2;
29 
30 
31 SWIGOUT(%rename(playbar) HOM_playbar;)
33 {
34 public:
35  virtual ~HOM_playbar()
36  {}
37 
38  virtual std::string __repr__() = 0;
39 
40  virtual bool isPlaying() = 0;
41  virtual void play() = 0;
42  virtual void stop() = 0;
43  virtual void reverse() = 0;
44 
45  virtual void jumpToNextKeyframe() = 0;
46  virtual void jumpToPreviousKeyframe() = 0;
47 
48  virtual HOM_EnumValue &playMode() = 0;
49  virtual void setPlayMode(HOM_EnumValue &mode) = 0;
50 
51  virtual double frameIncrement() = 0;
52  virtual void setFrameIncrement(double increment) = 0;
53 
54  SWIGOUT(%newobject playbackRange;)
55  virtual HOM_Vector2 *playbackRange() = 0;
56  virtual void setPlaybackRange(double start, double end) = 0;
57 
58  virtual bool isRangeRestricted() = 0;
59  virtual void setRestrictRange(bool on) = 0;
60 
61  virtual bool usesIntegerFrames() = 0;
62  virtual void setUseIntegerFrames(bool on) = 0;
63 
64  virtual bool isRealTime() = 0;
65  virtual void setRealTime(bool on) = 0;
66 
67  virtual double realTimeFactor() = 0;
68  virtual void setRealTimeFactor(double factor) = 0;
69 
70  virtual bool isRealTimeSkipping() = 0;
71  virtual void setRealTimeSkipping(bool on) = 0;
72 
73  virtual bool isAudioShown() = 0;
74  virtual void showAudio(bool on) = 0;
75  virtual bool areKeysShown() = 0;
76  virtual void showKeys(bool on) = 0;
77  virtual bool isSimCacheShown() = 0;
78  virtual void showSimCache(bool on) = 0;
79  virtual bool isRangeSliderShown() = 0;
80  virtual void showRangeSlider(bool on) = 0;
81  virtual bool areTicksShown() = 0;
82  virtual void showTicks(bool on) = 0;
83 
84  virtual void moveToBottom() = 0;
85  virtual void moveToPane(HOM_Pane &pane) = 0;
86 
87  SWIGOUT(%ignore addOpaqueEventCallback;)
88  virtual void addOpaqueEventCallback(void *callback) = 0;
89  SWIGOUT(%ignore removeOpaqueEventCallback;)
90  virtual void removeOpaqueEventCallback(void *callback) = 0;
91  SWIGOUT(%ignore opaqueEventCallbacks;)
92  virtual std::vector<void *> opaqueEventCallbacks() = 0;
93  SWIGOUT(%ignore clearOpaqueEventCallbacks;)
94  virtual void clearOpaqueEventCallbacks() = 0;
95 
96 #ifdef SWIG
97 %extend
98 {
99  void addEventCallback(InterpreterObject callback)
100  { self->addOpaqueEventCallback(callback); }
101 
102  void removeEventCallback(InterpreterObject callback)
103  { self->removeOpaqueEventCallback(callback); }
104 
105  void clearEventCallbacks()
106  { self->clearOpaqueEventCallbacks(); }
107 
108  // Note that we return a vector of borrowed references because swig
109  // will increment the reference counts.
110  std::vector<InterpreterObject> eventCallbacks()
111  {
112  std::vector<void *> opaque_callbacks(self->opaqueEventCallbacks());
113 
114  std::vector<InterpreterObject> callbacks;
115  for (int i=0; i< opaque_callbacks.size(); ++i)
116  callbacks.push_back((InterpreterObject)opaque_callbacks[i]);
117  return callbacks;
118  }
119 }
120 #endif
121 
122  virtual std::map<
124  std::vector< HOM_ElemPtr<HOM_BaseKeyframe> >
125  > selectedKeyframes() = 0;
126 
127  SWIGOUT(%newobject selectionRange;)
128  virtual HOM_Vector2 *selectionRange() = 0;
129 
130  virtual std::vector<HOM_ElemPtr<HOM_Vector2> > selectionRanges() = 0;
131 
132  SWIGOUT(%newobject timelineRange;)
133  virtual HOM_Vector2 *timelineRange() = 0;
134 
135  SWIGOUT(%newobject timeRange;)
136  virtual HOM_Vector2 *timeRange() = 0;
137  virtual void setTimeRange(double start, double end) = 0;
138 
139  SWIGOUT(%newobject frameRange;)
140  virtual HOM_Vector2 *frameRange() = 0;
141  virtual void setFrameRange(double start, double end) = 0;
142 
143  virtual void frameBookmark(HOM_Bookmark *bookmark) = 0;
144 
145  virtual HOM_ChannelList *channelList() = 0;
146  virtual void setChannelList( HOM_ChannelList *l ) = 0;
147 
148  virtual HOM_ChannelList *channelListFromSelection() = 0;
149  virtual HOM_ChannelList *channelListFromNodes(
150  const std::vector<HOM_Node*> &nodes) = 0;
151  virtual HOM_ChannelList *channelListFromParms(
152  const std::vector<HOM_Parm*> &parms) = 0;
153  virtual HOM_ChannelList *channelListFromParmTuples(
154  const std::vector<HOM_ParmTuple*> &parms) = 0;
155 };
156 
157 #endif
GLuint start
Definition: glcorearb.h:475
GLsizei const GLchar *const * string
Definition: glcorearb.h:814
#define SWIGOUT(x)
Definition: HOM_Defines.h:24
void reverse(I begin, I end)
Definition: pugixml.cpp:7190
string __repr__(VtArray< T > const &self)
Definition: wrapArray.h:352
#define HOM_API
Definition: HOM_API.h:13
void ignore(T const &) VULKAN_HPP_NOEXCEPT
Definition: vulkan.hpp:6508
GLuint GLuint end
Definition: glcorearb.h:475
virtual ~HOM_playbar()
Definition: HOM_playbar.h:35
GLenum mode
Definition: glcorearb.h:99
OIIO_UTIL_API bool rename(string_view from, string_view to, std::string &err)