35 #ifndef OPENMS_VISUAL_SPECTRUM3DOPENGLCANVAS_H
36 #define OPENMS_VISUAL_SPECTRUM3DOPENGLCANVAS_H
38 #include <QtOpenGL/QGLWidget>
45 class Spectrum3DCanvas;
83 void resizeGL(
int w,
int h);
87 GLuint makeDataAsStick();
91 GLuint makeAxesTicks();
93 GLuint makeDataAsTopView();
97 GLuint makeGridLines();
99 void drawAxesLegend();
103 void mouseMoveEvent(QMouseEvent * e);
104 void mouseReleaseEvent(QMouseEvent * e);
105 void mousePressEvent(QMouseEvent * e);
106 void focusOutEvent(QFocusEvent * e);
110 void computeSelection();
113 void updateIntensityScale();
116 void dataToZoomArray(
double x_1,
double y_1,
double x_2,
double y_2);
119 double scaledRT(
double rt);
121 double scaledInversRT(
double mz);
123 double scaledMZ(
double mz);
125 double scaledInversMZ(
double mz);
127 double scaledIntensity(
Real intensity,
Size layer_index);
130 void recalculateDotGradient_(
Size layer);
132 void calculateGridLines_();
135 float width()
const {
return width_; }
145 void normalizeAngle(
int * angle);
147 void setAngels(
int xrot,
int yrot,
int zrot);
149 void resetTranslation();
154 void storeRotationAndZoom();
156 void restoreRotationAndZoom();
229 void actionModeChange();
OpenGL Canvas for 3D-visualization of map data.
Definition: Spectrum3DOpenGLCanvas.h:55
double near_
member variable for the z- axis of the BB
Definition: Spectrum3DOpenGLCanvas.h:197
float Real
Real type.
Definition: Types.h:109
double x_1_
x1 coordinate of the zoomselection
Definition: Spectrum3DOpenGLCanvas.h:215
float width() const
return width
Definition: Spectrum3DOpenGLCanvas.h:135
std::vector< std::vector< double > > AxisTickVector
Container for axis ticks.
Definition: Spectrum3DOpenGLCanvas.h:65
float width_
the width of the viewport
Definition: Spectrum3DOpenGLCanvas.h:201
double x_2_
x2 coordinate of the zoomselection
Definition: Spectrum3DOpenGLCanvas.h:217
DRange< 1 > int_scale_
object wich contains the values of the current min and max intensity
Definition: Spectrum3DOpenGLCanvas.h:207
double trans_y_
y_translation
Definition: Spectrum3DOpenGLCanvas.h:225
int yrot_
member y-variables for the rotation
Definition: Spectrum3DOpenGLCanvas.h:173
double far_
member variable for the z- axis of the BB
Definition: Spectrum3DOpenGLCanvas.h:199
double y_1_
y1 coordinate of the zoomselection
Definition: Spectrum3DOpenGLCanvas.h:219
AxisTickVector grid_rt_
member gridvectors which contains the data for the rt-axis-ticks
Definition: Spectrum3DOpenGLCanvas.h:211
double zoom_tmp_
member variable that stores original zoom factor during zoom mode
Definition: Spectrum3DOpenGLCanvas.h:194
GLuint axes_
Definition: Spectrum3DOpenGLCanvas.h:161
double zoom_
member variable for the zoom mode
Definition: Spectrum3DOpenGLCanvas.h:192
AxisTickVector grid_mz_
member gridvectors which contains the data for the mz-axis-ticks
Definition: Spectrum3DOpenGLCanvas.h:209
int xRotation() const
return xRot_
Definition: Spectrum3DOpenGLCanvas.h:139
GLuint axes_ticks_
Definition: Spectrum3DOpenGLCanvas.h:162
int zRotation() const
return zRot_
Definition: Spectrum3DOpenGLCanvas.h:143
double corner_
member variable for the x and y axis of the BB
Definition: Spectrum3DOpenGLCanvas.h:190
AxisTickVector grid_intensity_
member gridvectors which contains the data for the intensity-axis-ticks
Definition: Spectrum3DOpenGLCanvas.h:213
int zrot_tmp_
member z-variable that stores the original angle during zoom mode
Definition: Spectrum3DOpenGLCanvas.h:182
double y_2_
y2 coordinate of the zoomselection
Definition: Spectrum3DOpenGLCanvas.h:221
int yrot_tmp_
member y-variable that stores the original angle during zoom mode
Definition: Spectrum3DOpenGLCanvas.h:180
int xrot_
member x-variables for the rotation
Definition: Spectrum3DOpenGLCanvas.h:171
float height() const
Definition: Spectrum3DOpenGLCanvas.h:136
float heigth_
the height of the viewport
Definition: Spectrum3DOpenGLCanvas.h:203
DRange< 3 > overall_values_
object which contains the min and max values of mz, rt and intensity
Definition: Spectrum3DOpenGLCanvas.h:205
GLuint stickdata_
Definition: Spectrum3DOpenGLCanvas.h:160
QPoint mouse_move_end_
member variables fot the zoom-modus
Definition: Spectrum3DOpenGLCanvas.h:187
Canvas for 3D-visualization of peak map data.
Definition: Spectrum3DCanvas.h:62
GLuint ground_
Definition: Spectrum3DOpenGLCanvas.h:164
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:144
Spectrum3DCanvas & canvas_3d_
reference to Spectrum3DCanvas
Definition: Spectrum3DOpenGLCanvas.h:168
double trans_x_
x- translation
Definition: Spectrum3DOpenGLCanvas.h:223
GLuint gridlines_
Definition: Spectrum3DOpenGLCanvas.h:163
int yRotation() const
return yRot_
Definition: Spectrum3DOpenGLCanvas.h:141
int xrot_tmp_
member x-variable that stores the original angle during zoom mode
Definition: Spectrum3DOpenGLCanvas.h:178
int zrot_
member z-variables for the rotation
Definition: Spectrum3DOpenGLCanvas.h:175