Issue launching AppImage on hybrid GPU system
Howdy! When I launch lovr.AppImage it returns this:
X Error of failed request: BadMatch (invalid parameter attributes)
Major opcode of failed request: 149 ()
Minor opcode of failed request: 4
Serial number of failed request: 265
Current serial number in output stream: 276
I have no clue why it does that, I even reinstalled it.
This looks very similar to this problem: https://github.com/bjornbytes/lovr/discussions/792
I have no idea what is causing it. Our GLFW is kind of old, I'll try upgrading it out of desperation.
The weird thing is the program worked on this same driver version a few weeks ago, so I don't get what is going wrong here. I did update to a new, untested nvidia driver and it still doesn't work.
I just pushed the GLFW upgrade if you wanna see if that helps. Also if you can post any system details like the driver version, distro, etc. it might help others that get the same issue or help with a potential fix.
For your info, here are my system specs:
OS: Ubuntu 24.04 LTS x86_64
Host: ASUS TUF Gaming F15 FX506HE_FX506HE 1.0
Kernel: 6.8.0-39-generic
Uptime: 3 hours, 22 mins
Packages: 2351 (dpkg), 16 (flatpak), 28 (snap)
Shell: bash 5.2.21
Resolution: 1080x1920, 1920x1080, 1920x1080
DE: GNOME 46.0
CPU: 11th Gen Intel i5-11400H (12) @ 4.500GHz
GPU: NVIDIA GeForce RTX 3050 Ti Mobile
GPU: Intel TigerLake-H GT1 [UHD Graphics]
Memory: 7224MiB / 15730MiB
Also, when I tried recompiling it gave me this error:
[ 0%] Built target xr_global_generated_files
[ 0%] Built target generate_openxr_header
[ 0%] Building CXX object openxr/src/loader/CMakeFiles/openxr_loader.dir/api_layer_interface.cpp.o
In file included from /home/gungu/lovr/deps/openxr/src/loader/loader_platform.hpp:16,
from /home/gungu/lovr/deps/openxr/src/loader/api_layer_interface.hpp:19,
from /home/gungu/lovr/deps/openxr/src/loader/api_layer_interface.cpp:10:
/home/gungu/lovr/deps/openxr/src/common/xr_dependencies.h:60:10: fatal error: xcb/glx.h: No such file or directory
60 | #include <xcb/glx.h>
| ^~~~~~~~~~~
compilation terminated.
gmake[2]: *** [openxr/src/loader/CMakeFiles/openxr_loader.dir/build.make:90: openxr/src/loader/CMakeFiles/openxr_loader.dir/api_layer_interface.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:1960: openxr/src/loader/CMakeFiles/openxr_loader.dir/all] Error 2
Luckily it isn't this version, since I also got this error a few hours ago when I compiled it for the second time.
To fix that compile error you can install libxcb-glx0-dev, full list of required packages is here. The AppImage from CI is also available if that's easier
Thanks! I compiled the whole thing but sadly it still gives the same error.
X Error of failed request: BadMatch (invalid parameter attributes)
Major opcode of failed request: 149 ()
Minor opcode of failed request: 4
Serial number of failed request: 262
Current serial number in output stream: 273
At this point I have no clue what the issue is.
Both people experiencing this issue are on dual iGPU/dGPU setups. Apparently disabling the iGPU in BIOS fixes it. Hopefully we can find a better workaround though.
Yeah, I'm hoping for a better workaround, because I have an Asus tuf 15 laptop, and they don't allow disabling the iGPU in the bios, since they got rid of the MUX switch.
Hi! Got another update on this issue. The app works perfectly fine with noveau drivers, my only issue is that I've got a usb-c display which doesn't work with noveau drivers, but I'm gonna get that figured out. Maybe it also works on older driver version, I'm also gonna try that.
Another crazy discorvery, I downgraded drivers and I even tried with current driver versions, and it worked completely fine, up until I used the command
sudo prime-select nvidia
which ended up stopping the application from working. I'm just gonna leave out that function because I don't play games on linux anymore, and I guess it'll work. I'll still not close this issue though, since it isn't technically fixed
To prevent duplicate issues, I decided to come here. I tried both latest release, AppImage and manual build of manual development version, but it all leads to similar error:
X Error of failed request: 136 Major opcode of failed request: 148 () Minor opcode of failed request: 1 Serial number of failed request: 270 Current serial number in output stream: 270
The error was taken with manually initiated window(under lovr.load), so it may have some part different.
GLFW version on the development version is 3.50.(found in CMakeLists)
Thank you for the info. If you're building from source you could try building with -DLOVR_USE_GLFW=OFF, I'm curious if this would change anything (this uses raw xcb instead of GLFW).
Weirdly, I got a blank window with this on "no game" display.
Text looks normal on my project, but it is just a black screen, and the log(my logging system) is stopping from certain place.
I enabled debug log, this is the output:
Error [GENERAL | xrEnumerateInstanceExtensionProperties | OpenXR-Loader] : RuntimeManifestFile::FindManifestFiles - failed to determine active runtime file path for this environment Error [GENERAL | xrEnumerateInstanceExtensionProperties | OpenXR-Loader] : RuntimeInterface::LoadRuntimes - unknown error Error [GENERAL | xrEnumerateInstanceExtensionProperties | OpenXR-Loader] : RuntimeInterface::LoadRuntimes - failed to load a runtime Error [GENERAL | xrEnumerateInstanceExtensionProperties | OpenXR-Loader] : Failed to find default runtime with RuntimeInterface::LoadRuntime() Error [GENERAL | xrEnumerateInstanceExtensionProperties | OpenXR-Loader] : Failed querying extension properties Warning: GPU debugging is enabled, but validation layer is not installed
This happened with "no game". For my project, it only shows the last warning(Due to lovr.headset being disabled?).
Note: The weird text issue did not occur on 0.17.1 with GLFW, where the software crashes.
Has anyone tried the __NV_PRIME_RENDER_OFFLOAD environment variable?
__NV_PRIME_RENDER_OFFLOAD=1 lovr
Nothing changed, with both GLFW and XCB.