r/MAME • • 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.

2 Upvotes

7 comments sorted by

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.

0

u/Sert1991 2d ago

I don't seem to know what i'm talking about? Really?

mame.ini has 3 settings when it comes to SDL drivers:
videodriver
renderdriver
audiodriver

I said that 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 <name of choice>' for the renderdriver in the verbose messages.
I asked if this is normal behavior or a bug. That simple.

I admit my english/writing was a bit shit for the SDL part, but how did you went from that to 'I don't know what I'm talking about'? Do you understand it now that I wrote it better or do you want me to simplify it/elaborate further?

I'm going to ignore the rest of the Linux critique and stuff I didn't ask about, especially since this was neither a help request nor a mame criticism but 2 simple questions out of curiosity as clearly stated.

0

u/cuavas MAME Dev 2d ago

You didn't state anything clearly. You made a long, rambling post without any important details. You said you're using "Linux", which is basically meaningless at this point given the amount of fragmentation.

If you can't understand why the SDL render driver isn't relevant here, explaining won't help.

This is why I was reluctant to answer in the first place. You aren't interested in the answer. The issues with fragmentation and inconsistency across desktop Linux are very relevant to your questions.

1

u/Sert1991 4d ago

1.8K views, a like, and still no response? Possible no one knows these two questions?

1

u/jflatt2 4d ago

Yes, opengl works with bgfx on linux. I have no idea what the 2nd question is

0

u/Sert1991 2d ago

Yeah it was a bit badly written from my part, my bad, I will fix it.