mirror of
https://github.com/YACReader/yacreader
synced 2026-04-12 15:49:53 -04:00
Add an initial rhi implementation that mimics the opengl implementation
This commit is contained in:
@ -204,6 +204,12 @@ void LibraryWindow::setupOpenglSetting()
|
||||
// FLOW-----------------------------------------------------------------------
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 7, 0) && defined(YACREADER_USE_RHI)
|
||||
// When using RHI, assume hardware acceleration is available
|
||||
bool openGLAvailable = true;
|
||||
if (!settings->contains(USE_OPEN_GL))
|
||||
settings->setValue(USE_OPEN_GL, 2);
|
||||
#else
|
||||
OpenGLChecker openGLChecker;
|
||||
bool openGLAvailable = openGLChecker.hasCompatibleOpenGLVersion();
|
||||
|
||||
@ -212,6 +218,7 @@ void LibraryWindow::setupOpenglSetting()
|
||||
else if (!openGLAvailable)
|
||||
settings->setValue(USE_OPEN_GL, 0);
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
void LibraryWindow::setupUI()
|
||||
|
||||
Reference in New Issue
Block a user