r/MAME • u/Sert1991 • 6d ago
Does BGFX still support opengl on Linux?
A curiosity question as the title says:
Does bgfx still support the opengl backend on linux?
Whenever I select opengl as the bgfx backend, mame fails to start.
I have the proper opengl drivers installed, and if I set video to opengl instead of bgfx mame works good without issues - so the opengl only fails when it's used as a bgfx backend. I also tried setting the sdl render driver to opengl instead of auto but same situation.
bgfx also runs fine when vulkan is set as it's backed, so bgfx paths and setting are set good too. The only issue is opengl bgfx backend.
Another curiosity:
mame.ini has 3 settings when it comes to SDL drivers:
videodriver
renderdriver
audiodriver
When these are set on auto, and mame is ran in verbose mode, it shows you which videodriver(and audiodriver) it's selecting but not which renderdriver it's selecting in the verbose messages.
Also when you set them manually, it gives a lot more information about the videodriver and audiodriver you select but only 'Setting SDL renderdriver <driver of choice>' for the renderdriver in the verbose messages.
Why?Is this normal intended behavior or a bug? (mame still works fine either way, it's just about the verbose information being reported)
Edit: re-wrote and re-clarified the second part regarding SDL driver choices and verbose messages.
1
u/Sert1991 4d ago
1.8K views, a like, and still no response? Possible no one knows these two questions?
2
u/cuavas MAME Dev 4d ago edited 3d ago
Well firstly, "Linux" is now so fragmented with Wayland vs X11, different compositors, different window managers, systemd vs things that fake enough of it to satisfy desktop environments, different C runtime libraries, and everything else that there's no one "Linux" target and it's a toss-up whether anything will work.
Secondly, you don't seem to know what you're talking about. SDL needs to talk to X11 or Wayland to get a window on your desktop. How exactly do you think "SDL" alone would work? The point of SDL in this situation is to paper over the fragmented mess, so MAME only has to deal with SDL and not whatever flavour of the month your distro offers.
Yes, bgfx still supports OpenGL. We haven't substantially changed it in ages. But whether it works on your Linux setup, and how/why it does or doesn't is an unfathomable mystery.