src/glcamera.h

changeset 1404
16eb4257e662
parent 1326
69a90bd2dba2
child 1437
1a77c6156db7
equal deleted inserted replaced
1403:7a2d84112983 1404:16eb4257e662
20 #include "main.h" 20 #include "main.h"
21 #include "glShared.h" 21 #include "glShared.h"
22 22
23 struct FixedCameraParameters 23 struct FixedCameraParameters
24 { 24 {
25 GLRotationMatrix rotationMatrix; 25 QMatrix4x4 rotationMatrix;
26 Axis localX; 26 Axis localX;
27 Axis localY; 27 Axis localY;
28 bool negatedX; 28 bool negatedX;
29 bool negatedY; 29 bool negatedY;
30 bool negatedZ; 30 bool negatedZ;
57 double panningX() const; 57 double panningX() const;
58 double panningY() const; 58 double panningY() const;
59 Q_SLOT void rendererResized(int width, int height); 59 Q_SLOT void rendererResized(int width, int height);
60 void setPanning(double x, double y); 60 void setPanning(double x, double y);
61 void setZoom(double zoom); 61 void setZoom(double zoom);
62 const GLRotationMatrix& transformationMatrix() const; 62 const QMatrix4x4& transformationMatrix() const;
63 GLRotationMatrix transformationMatrix(double scale) const; 63 QMatrix4x4 transformationMatrix(double scale) const;
64 const QSizeF& virtualSize() const; 64 const QSizeF& virtualSize() const;
65 double zoom() const; 65 double zoom() const;
66 void zoomNotch(bool inward); 66 void zoomNotch(bool inward);
67 GLRotationMatrix realMatrix() const; 67 QMatrix4x4 realMatrix() const;
68 68
69 private: 69 private:
70 QString m_name; 70 QString m_name;
71 double m_panningX = 0; 71 double m_panningX = 0;
72 double m_panningY = 0; 72 double m_panningY = 0;
73 double m_depth = 0; 73 double m_depth = 0;
74 double m_zoom = 30; 74 double m_zoom = 30;
75 QSize m_size; 75 QSize m_size;
76 QSizeF m_virtualSize; 76 QSizeF m_virtualSize;
77 GLRotationMatrix m_rotationMatrix; 77 QMatrix4x4 m_rotationMatrix;
78 Axis m_localX = X; // Which axis to use for Y 78 Axis m_localX = X; // Which axis to use for Y
79 Axis m_localY = Y; // Which axis to use for Y 79 Axis m_localY = Y; // Which axis to use for Y
80 bool m_isFree = false; // Is this the free camera? 80 bool m_isFree = false; // Is this the free camera?
81 bool m_negatedX = false; // Is +x to the left? 81 bool m_negatedX = false; // Is +x to the left?
82 bool m_negatedY = false; // Is +y downwards? 82 bool m_negatedY = false; // Is +y downwards?

mercurial