ISceneController.h
Go to the documentation of this file.
1 #ifndef i2d_ISceneController_included
2 #define i2d_ISceneController_included
3 
4 
5 #include <istd/IPolymorphic.h>
6 
7 #include <i2d/i2d.h>
8 
9 
10 namespace i2d
11 {
12 
13 
17 class ISceneController: virtual public istd::IPolymorphic
18 {
19 public:
21  {
25  SR_NONE = 0x0,
26 
30  SR_ROTATE = 0x1,
31 
35  SR_SHIFT = 0x2,
36 
40  SR_SCALE = 0x4,
41 
45  SR_ALL = 0xff
46  };
47 
51  enum FitMode{
68  };
69 
73  enum ScaleMode
74  {
107  };
108 
112  virtual int GetSceneRestrictionFlags() const = 0;
113 
117  virtual FitMode GetFitMode() const = 0;
123  virtual bool SetFitMode(FitMode fitMode) = 0;
124 
129  virtual bool IsFullScreenMode() const = 0;
136  virtual bool SetFullScreenMode(bool isFullScreen) = 0;
137 
141  virtual double GetScale() const = 0;
146  virtual bool SetScale(int scaleMode = SM_SET, double value = 1.0) = 0;
147 };
148 
149 
150 } // namespace i2d
151 
152 
153 #endif // !i2d_ISceneController_included
154 
155 
No fitting will be done.
virtual int GetSceneRestrictionFlags() const =0
Get the restriction flags, to tell the scene manipulator, what can be changed on the scene...
All operations on scene object are prohibited.
Zoom out will be done, parameter value will be ignored.
All operations on scene object are allowed.
Anisotropic scale will be done to fit whole viewport area.
Zoom will be reset, parameter value will be ignored.
virtual bool SetFitMode(FitMode fitMode)=0
Set vieport scale fitting mode.
Isotropic scale will be done, but only scale reduction is allowed.
ScaleMode
Describe mode for setting of scale value.
Translation operaration is prohibited.
FitMode
Vieport scale fitting mode.
Zoom in will be done, parameter value will be ignored.
Complete isotropic scale will be done.
Base interface for all used interfaces and implementations.
Definition: IPolymorphic.h:17
virtual double GetScale() const =0
Get actual scale factor.
Isotropic scale will be done, but only scale reduction is allowed.
Rotation operaration is prohibited.
Interface for scene manipulation and query the restrictions.
virtual FitMode GetFitMode() const =0
Get vieport scale fitting mode.
Anisotropic scale will be done to fit whole viewport area.
virtual bool SetScale(int scaleMode=SM_SET, double value=1.0)=0
Set or modify scale factor.
Old scale will be mutliplied by the new value.
Simple set, old scale will be replaced with the new value.
virtual bool SetFullScreenMode(bool isFullScreen)=0
Set full screen mode on/off.
Complete isotropic scale will be done.
virtual bool IsFullScreenMode() const =0
Check if full screen mode is enabled.
Translation operaration is prohibited.

© 2007-2017 Witold Gantzke and Kirill Lepskiy