Consider an improved probing logic in addition to the static QSG_RHI_BACKEND (or setSceneGraphBackend()) setting. What if we want the Qt Quick application to try Vulkan first and then fall back to OpenGL if that fails, for example?
Note that in some cases it is not trivial to recognize if the graphics API is unsupported: as QTBUG-78648 shows, the fact that D3D11 is not supported only becomes apparent when trying to create an actual ID3D11 resource, such as a vertex shader. Successfully creating an ID3D11Device is not sufficient to decide if we D3D11 is ok or not, apparently. (see also the Remarks section in https://docs.microsoft.com/en-us/windows/win32/api/dxgi/nf-dxgi-idxgiadapter-checkinterfacesupport )