Commit cda16538 authored by Marc R.'s avatar Marc R.

skew-T: revised drawing of coordinate lines and adiabates during full screen...

skew-T: revised drawing of coordinate lines and adiabates during full screen mouse over in interaction mode
parent a91b66e8
This diff is collapsed.
......@@ -165,6 +165,7 @@ private:
*/
struct VertexRanges
{
int lineWidth = 1;
VertexRange temperatureMarks;
VertexRange isotherms;
VertexRange dryAdiabates;
......@@ -349,6 +350,8 @@ private:
QVector<QVector2D> dryAdiabatesVertices;
QVector<QVector2D> moistAdiabatesVertices;
QString bufferNameSuffix;
VertexRanges highlightGeometryDrawRanges;
};
ModeSpecificDiagramConfiguration normalscreenDiagrammConfiguration;
......@@ -399,6 +402,7 @@ private:
*/
GL::MVertexBuffer* vbDiagramVertices;
GL::MVertexBuffer* vbDiagramVerticesFS;
GL::MVertexBuffer* vbHighlightVertices;
/**
@brief Buffer used for the actual wyoming station.
......@@ -430,12 +434,18 @@ private:
void copyDiagramConfigurationFromQtProperties();
void drawDiagramGeometryAndLabels(MSceneViewGLWidget*sceneView,
GL::MVertexBuffer *vbDiagramVertices,
ModeSpecificDiagramConfiguration *config);
GL::MVertexBuffer *vbDiagramVertices,
ModeSpecificDiagramConfiguration *config,
VertexRanges *vertexRanges);
void generateDiagramGeometry(GL::MVertexBuffer **vbDiagramVertices,
ModeSpecificDiagramConfiguration *config);
void generateFullScreenHighlightGeometry(
QVector2D tpCoordinate,
GL::MVertexBuffer** vbDiagramVertices,
ModeSpecificDiagramConfiguration *config);
void drawDiagram(MSceneViewGLWidget* sceneView,
GL::MVertexBuffer *vbDiagramVertices,
ModeSpecificDiagramConfiguration *config);
......@@ -464,6 +474,7 @@ private:
// into the diagram's (x, y) coordinates. Computed by
// computeTlogp2xyTransformationMatrix().
QMatrix4x4 transformationMatrixTlogp2xy;
QMatrix4x4 transformationMatrixXY2Tlogp; // inverse matrix
/**
Compute the @ref transformationMatrixTlogp2xy from user settings
......@@ -482,6 +493,11 @@ private:
*/
QVector2D transformTp2xy(QVector2D tpCoordinate_K_hPa);
/**
Inverse of @ref transformTp2xy().
*/
QVector2D transformXY2Tp(QVector2D xyCoordinate);
/**
Transform a Skew-T diagram's (x, y) coordinate into full-screen clip
space coordinates.
......@@ -492,6 +508,11 @@ private:
*/
QVector2D transformXY2ClipSpace(QVector2D xyCoordinate);
/**
Inverse of transformXY2ClipSpace
*/
QVector2D transformClipSpace2xy(QVector2D clipCoordinate);
/**
Computes a view-dependent transformation matrix to transform coordinates
in the diagram's (x, y) space into a scene view's world space.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment