8 #include <QOpenGLBuffer> 9 #include <QOpenGLFunctions> 10 #include <QOpenGLShaderProgram> 11 #include <QOpenGLVertexArrayObject> 12 #include <QOpenGLWidget> 24 #define GLES100 "1.00 ES" 25 #define GLSL120 "1.20" 26 #define GLSL150 "1.50" 43 void showData( std::shared_ptr< PPresult > newData );
49 void generateGrid(
int index = -1,
double value = 0.0,
bool pressed =
false );
68 void resizeGL(
int width,
int height )
override;
74 void wheelEvent( QWheelEvent *event )
override;
75 void paintEvent( QPaintEvent *event )
override;
82 void drawVertices( QOpenGLFunctions *gl,
unsigned marker, QColor color );
89 void markerMoved(
unsigned cursorIndex,
unsigned marker );
99 #pragma pack( push, 1 ) 119 void draw4Cross( std::vector< QVector3D > &va,
int section,
float x,
float y );
unsigned selectedMarker
Definition: glscope.h:106
QOpenGLVertexArrayObject m_vaoGrid[gridItems]
Definition: glscope.h:117
void drawSpectrumChannelGraph(ChannelID channel, Graph &graph, int historyIndex)
Definition: glscope.cpp:856
void updateCursor(unsigned index=0)
Definition: glscope.cpp:504
int colorLocation
Definition: glscope.h:134
void mouseReleaseEvent(QMouseEvent *event) override
Definition: glscope.cpp:195
DsoSettingsScope * scope
Definition: glscope.h:93
std::vector< DsoSettingsScopeCursor *> cursorInfo
Definition: glscope.h:111
std::unique_ptr< QOpenGLShaderProgram > m_program
Definition: glscope.h:132
bool zoomed
Definition: glscope.h:95
void resizeGL(int width, int height) override
Resize the widget.
Definition: glscope.cpp:567
int vertexLocation
Definition: glscope.h:135
void wheelEvent(QWheelEvent *event) override
Definition: glscope.cpp:244
DsoSettingsView * view
Definition: glscope.h:94
static QString getGLSLversion()
Definition: glscope.h:38
QVector3D a
Definition: glscope.h:101
int selectionLocation
Definition: glscope.h:137
void markerMoved(unsigned cursorIndex, unsigned marker)
Definition: glscope.h:100
std::vector< Vertices > vaMarker
Definition: glscope.h:105
QOpenGLBuffer m_marker
Definition: glscope.h:107
QVector3D b
Definition: glscope.h:101
void draw4Cross(std::vector< QVector3D > &va, int section, float x, float y)
Definition: glscope.cpp:591
~GlScope() override
Definition: glscope.cpp:82
QString renderInfo
Definition: glscope.h:129
void drawHistogramChannelGraph(ChannelID channel, Graph &graph, int historyIndex)
Definition: glscope.cpp:843
void generateVertices(unsigned marker, const DsoSettingsScopeCursor &cursor)
Definition: glscope.cpp:468
void drawMarkers()
Draw vertical lines at marker positions.
Definition: glscope.cpp:802
QPointF posToPosition(QPointF pos)
Definition: glscope.cpp:104
QMatrix4x4 pmvMatrix
projection, view matrix
Definition: glscope.h:133
bool shaderCompileSuccess
Definition: glscope.h:130
void initializeGL() override
Initializes OpenGL output.
Definition: glscope.cpp:298
QVector3D d
Definition: glscope.h:101
const unsigned NO_MARKER
Definition: glscope.h:98
QOpenGLBuffer m_grid
Definition: glscope.h:115
QOpenGLVertexArrayObject m_vaoMarker
Definition: glscope.h:108
QColor triggerLineColor
Definition: glscope.h:120
void mouseMoveEvent(QMouseEvent *event) override
Definition: glscope.cpp:172
QVector3D c
Definition: glscope.h:101
void drawVoltageChannelGraph(ChannelID channel, Graph &graph, int historyIndex)
Definition: glscope.cpp:830
const unsigned VERTICES_ARRAY_SIZE
Definition: glscope.h:104
Holds the cursor parameters.
Definition: scopesettings.h:16
unsigned currentGraphInHistory
Definition: glscope.h:124
OpenGL accelerated widget that displays the oscilloscope screen.
Definition: glscope.h:29
void drawVertices(QOpenGLFunctions *gl, unsigned marker, QColor color)
Definition: glscope.cpp:791
Definition: glscopegraph.h:16
void drawGrid()
Draw the grid.
Definition: glscope.cpp:756
Holds all view settings.
Definition: viewsettings.h:35
void mouseDoubleClickEvent(QMouseEvent *event) override
Definition: glscope.cpp:211
static GlScope * createNormal(DsoSettingsScope *scope, DsoSettingsView *view, QWidget *parent=nullptr)
Definition: glscope.cpp:89
void generateGrid(int index=-1, double value=0.0, bool pressed=false)
Definition: glscope.cpp:608
void showData(std::shared_ptr< PPresult > newData)
Definition: glscope.cpp:444
static const int gridItems
Definition: glscope.h:116
unsigned ChannelID
Definition: types.h:6
int matrixLocation
Definition: glscope.h:136
static QString getOpenGLversion()
Definition: glscope.cpp:32
QString errorMessage
Definition: glscope.h:131
GLsizei gridDrawCounts[gridItems]
Definition: glscope.h:118
Holds the settings for the oscilloscope.
Definition: scopesettings.h:82
void paintGL() override
Draw the graphs, marker and the grid.
Definition: glscope.cpp:518
GlScope(DsoSettingsScope *scope, DsoSettingsView *view, QWidget *parent=nullptr)
Initializes the scope widget.
Definition: glscope.cpp:65
static QString OpenGLversion
Definition: glscope.h:127
unsigned selectedCursor
Definition: glscope.h:112
static GlScope * createZoomed(DsoSettingsScope *scope, DsoSettingsView *view, QWidget *parent=nullptr)
Definition: glscope.cpp:97
std::list< Graph > m_GraphHistory
Definition: glscope.h:123
void paintEvent(QPaintEvent *event) override
Definition: glscope.cpp:282
#define GLSL120
Definition: glscope.h:25
static void useOpenGLSLversion(QString version=GLSL120)
Definition: glscope.cpp:48
void cursorSelected(unsigned index)
Definition: glscope.h:45
static QString GLSLversion
Definition: glscope.h:128
Post processing results.
Definition: ppresult.h:37
void mousePressEvent(QMouseEvent *event) override
Definition: glscope.cpp:118