-
-
Notifications
You must be signed in to change notification settings - Fork 957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[desktop][drape] Black screen with new Qt 6.7 #7838
Comments
The workaround is to downgrade to Qt 6.6, here is how to do it on a Mac using brew:
Upd: to avoid automatic qt update, use:
When the bug will be fixed:
|
Please put instructions into ./scripts/unix/install-qt-mac.sh |
Good idea @rtsisyk! can you please help? |
Confirm solution for my Apple M1 Pro. |
I have the same issue (with Qt 6.7.0, Wayland with Kwin 6.0.4.1). Here is my log, when starting OMaps (it does not contain the above error):
Additionally,
The app reacts normally (when I zoom in, it offers to download the map, it displays all the buttons). It's just the map that is completely black. |
BTW:
Here, the renderer can take a different path: if (context()->format().version() < qMakePair(3, 0))
{
LOG(LINFO, ("OpenGL ES version is below 3.0, taking the OpenGL ES 2.0 path"));
m_apiOpenGLES3 = false;
constexpr const char* requiredExtensions[3] =
{ "GL_EXT_map_buffer_range", "GL_OES_mapbuffer", "GL_OES_vertex_array_object" };
for (auto & requiredExtension : requiredExtensions)
{
if (context()->hasExtension(QByteArray::fromStdString(requiredExtension)))
LOG(LDEBUG, ("Found OpenGL ES 2.0 extension: ", requiredExtension));
else
LOG(LCRITICAL, ("A required OpenGL ES 2.0 extension is missing:", requiredExtension));
}
fmt.setProfile(QSurfaceFormat::CompatibilityProfile);
fmt.setVersion(2, 0);
}
else
{
LOG(LINFO, ("OpenGL version is at least 3.0, enabling GLSL '#version 300 es'"));
m_apiOpenGLES3 = true;
fmt.setVersion(3, 0);
} I changed the condition in the |
Qt 6 has new (more native) graphics API support. OM still uses Qt 5 style rendering. I think it's a question of time when it stops working completely in Qt 6. |
@renderexpert this regression started specifically from Qt 6.7, lower versions were working fine. What is a "Qt6" graphics approach? Are there any Qt5 migration examples or documentation? |
@biodranik I got it that it was for Qt 6.7 only. What I meant that in time such bugs will appear more and more until eventually older approach is deprecated. Some example from the blog: "In general everything that worked in Qt 5 can be expected to work in Qt 6, with the exception of deprecated and now-removed functionality, such as all the Qt 4 era classes with the QGL prefix (most notably, QGLWidget). If a Qt 5 application renders its own OpenGL content into a QWindow, or uses QOpenGLWidget, it will all function as before. (in the worst case with some very minor migration steps, e.g. having to update the application project file due to QOpenGLWidget moving to its own module openglwidgets)." |
Is there another workaround than downgrading? So - if there are multiple rendering backends - maybe it is possible to switch to another one (pure software rendering for example), even if it's really slow. |
It would be great to investigate Qt6 OpenGL examples and try to rewrite our current implementation. Or find a source of this nasty bug and fix it... CC @Ferenc- |
The source of this nasty bug appears to be, that while the usual first colour pass made by by drape via
A least this does not ruin the original textures. After this pass, drape still renders the map perfectly:
|
Thanks for the investigation! It looks related to some QWindow/QRhi modifications in Qt 6.7: Could it be that the Maybe it would be feasible to find what causes the error below by enabling OpenGL debugging?
|
@Ferenc- probably not related to the issue, but I've noticed that organicmaps/qt/qt_common/map_widget.cpp Line 492 in a342a83
|
@Osyotr good catch! Although it doesn't fix the black screen on the Mac. Do you have the same issue on Windows with Qt 6.7? |
Yeah though I have other graphical issues as well (not related to Qt 6.7; probably some synchronization issues). |
Surprisingly, gutting out |
@Ferenc- do you have a branch with your experiments? |
Looks like the workaround for Mac brew above doesn't work due to the wrong icu version (it was updated in brew and should also be downgraded to work with older Qt version), CMake configure fails without working uic binary:
|
After updating on Qt 6.7.
Qt 6.6.3 works fine.
Part of the init log, see "GLError: 1286"
@Ferenc- @renderexpert Maybe you have any ideas.
The text was updated successfully, but these errors were encountered: