Migrate to Qt6

This commit is contained in:
2023-12-20 11:21:46 +01:00
parent aef41f5f6b
commit eaf2c7094b
4 changed files with 10 additions and 11 deletions
+2 -1
View File
@@ -1,5 +1,6 @@
#include "imagescrollareagl.h"
#include <QOpenGLFunctions>
#include <QOpenGLVersionFunctionsFactory>
#include <QDebug>
#include <QKeyEvent>
#include <QOpenGLDebugLogger>
@@ -400,7 +401,7 @@ void ImageWidget::initializeGL()
{
f = context()->functions();
f->glClearColor(0.5f, 0.5f, 0.5f, 1.0f);
f3 = context()->versionFunctions<QOpenGLFunctions_3_3_Core>();
f3 = QOpenGLVersionFunctionsFactory::get<QOpenGLFunctions_3_3_Core>(context());
if(f3 == nullptr)
QMessageBox::critical(this, tr("OpenGL error"), tr("Could not initialize OpenGL 3.3 context. Ensure that proper GPU driver is installed."));