22 #ifndef GLSCENEZOOMANDPAN_H_
23 #define GLSCENEZOOMANDPAN_H_
25 #include <tulip/tulipconf.h>
26 #include <tulip/Vector.h>
27 #include <tulip/Coord.h>
41 class TLP_GL_SCOPE AdditionalGlSceneAnimation {
44 virtual ~AdditionalGlSceneAnimation() {}
51 inline void setNbAnimationSteps(
int nbAnimationSteps) {
52 this->nbAnimationSteps = nbAnimationSteps;
61 virtual void animationStep(
int animationStep) = 0;
79 class TLP_GL_SCOPE GlSceneZoomAndPan {
82 virtual ~GlSceneZoomAndPan() {}
98 GlSceneZoomAndPan(GlScene *glScene,
const BoundingBox &boundingBox,
99 const std::string &layerName =
"Main",
const int nbAnimationSteps = 50,
100 const bool optimalPath =
true,
const double p = sqrt(1.6));
107 void setAdditionalGlSceneAnimation(AdditionalGlSceneAnimation *additionalAnimation);
112 inline int getNbAnimationsStep()
const {
113 return nbAnimationSteps;
119 inline void setNbAnimationSteps(
const int nbAnimationSteps) {
120 this->nbAnimationSteps = nbAnimationSteps;
129 void zoomAndPanAnimationStep(
int animationStep);
133 Vector<int, 4> viewport;
134 int nbAnimationSteps;
137 Coord camCenterStart, camCenterEnd;
138 double w0, w1, u0, u1, b0, b1, r0, r1, S, sA, sB, wm;
139 AdditionalGlSceneAnimation *additionalAnimation;
140 float zoomAreaWidth, zoomAreaHeight;