rhi: Don't fall back to OpenGL backingstore if Metal is not available
We were reusing the QRhiMetalInitParams when falling back to OpenGL, which caused crashes at runtime. We remove the fallback altogether, as tests or clients that rely on a specific RHI backingstore backend should do feature-testing before requesting the specific backend. Pick-to: 6.7 Change-Id: Iee38348ae06ea118aafcada33a8956ae07bb2228 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>bb10
parent
529267972b
commit
bc1f983781
|
|
@ -114,8 +114,8 @@ bool QBackingStoreRhiSupport::create()
|
|||
if (QRhi::probe(QRhi::Metal, ¶ms)) {
|
||||
rhi = QRhi::create(QRhi::Metal, ¶ms, flags);
|
||||
} else {
|
||||
qCDebug(lcQpaBackingStore, "Metal does not seem to be supported. Falling back to OpenGL.");
|
||||
rhi = QRhi::create(QRhi::OpenGLES2, ¶ms, flags);
|
||||
qCDebug(lcQpaBackingStore, "Metal does not seem to be supported");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in New Issue