Announcement

Collapse
No announcement yet.

Ubuntu 19.10 Is The First Time We've Seen (X)Wayland Gaming Performance Match X.Org

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #21
    Wasn't able to get nvidia drivers working under GNOME Wayland correctly last time I tested it out (couple weeks back). It did render the desktop but adjusting settings was problematic.

    Comment


    • #22
      Originally posted by dos1 View Post

      SDL2 by default tries to use system's SDL version even when it's statically linked - you can prevent it, but you really have to want to do it.

      The real problem is that setting SDL_VIDEODRIVER variable globally will lead to broken games, because it also affects SDL1 - so the real solution is to wait until SDL2 starts to prefer Wayland backend over X11 (which won't happen until the situation around window decoration isn't somehow resolved).
      My understanding was that it'll accept being statically linked just fine, trusting that people who do that have done the portability testing to justify it, but it has its own dynamic dispatch system that hooks everything up on Init so it can provide its own environment variable akin to LD_PRELOAD that lets you ask a statically linked SDL2 to dlopen some other SDL and hand off to it instead. (Thus ruling out a repeat of "this SDL2 is too old support PulseAudio or Wayland and the devs aren't going to do a new build".)

      Has that changed?

      Comment


      • #23
        Originally posted by theriddick View Post
        Wasn't able to get nvidia drivers working under GNOME Wayland correctly last time I tested it out (couple weeks back). It did render the desktop but adjusting settings was problematic.
        Blame Nvidia, not Wayland.

        Originally posted by jacob View Post

        Proton won't support that until Wine does, and Wine can't.
        But that only concerns Windows games on Linux. For native games there won't be any excuse when Wayland is default.
        I believe Wayland support is planned for Wine afaik.

        I think the big blocker is under Wayland, clients can't draw to exact co-ordinates on the screen, which Wine/Windows uses for menus. This isn't important for games though and you could probably work around by translating co-ordinates.

        Comment


        • #24
          Originally posted by jacob View Post

          People don't use LD_PRELOAD or give a sh!t about backends. People click on "Play" in Steam, period and full stop.
          Unless Play doesn't work. I've used LD_PRELOAD a few times for some titles as they would not run otherwise since I'm not on Ubuntu and they link to some outdated lib or something(can't remember exact issue, pretty sure I was using the steam runtime too).

          Comment


          • #25
            Originally posted by ernstp View Post

            I guess that many already do just by using SDL... ?
            Are there anyone analyzing proprietary game ports for looking to dependencies and if they include dynamic libraries or those are statically compiled? I always thought about this.

            If SDL is dynamically compiled, I guess if would be possible to back backport Wayland support or make a shim library for it. Am I right?

            If SDL is statically compiled, I guess it would be more difficult. What about reverse the executable to replace the statically linked SDL with a SDL with Wayland support or a shim library? Is it possible?

            Are there proprietary game ports not using SDL? Since Icculus started SDL as a way of making Linux ports easier, I guess that would be a rare case.

            Would it be possible to play older Linux ports of games without X or XWayland in some way? I really hope it can be possible!

            Can anyone reply to some or all of these questions? Please!

            Comment


            • #26
              Originally posted by dos1 View Post

              SDL2 by default tries to use system's SDL version even when it's statically linked - you can prevent it, but you really have to want to do it.

              The real problem is that setting SDL_VIDEODRIVER variable globally will lead to broken games, because it also affects SDL1 - so the real solution is to wait until SDL2 starts to prefer Wayland backend over X11 (which won't happen until the situation around window decoration isn't somehow resolved).
              Right, SDL_VIDEODRIVER=wayland . Huh, there should be a SLD2_VIDEODRIVER variable.

              Comment


              • #27
                Originally posted by timofonic View Post

                Are there anyone analyzing proprietary game ports for looking to dependencies and if they include dynamic libraries or those are statically compiled? I always thought about this.

                If SDL is dynamically compiled, I guess if would be possible to back backport Wayland support or make a shim library for it. Am I right?

                If SDL is statically compiled, I guess it would be more difficult. What about reverse the executable to replace the statically linked SDL with a SDL with Wayland support or a shim library? Is it possible?

                Are there proprietary game ports not using SDL? Since Icculus started SDL as a way of making Linux ports easier, I guess that would be a rare case.

                Would it be possible to play older Linux ports of games without X or XWayland in some way? I really hope it can be possible!

                Can anyone reply to some or all of these questions? Please!
                SDL2 is super special AFAIK. After it loads, it looks for other SDL2 libraries available and if they're newer it dynamically replaces itself with that!

                Comment


                • #28
                  As long as Freesync isn't supported under Wayland I can't really see me making the switch for gaming.

                  Comment


                  • #29
                    With 3.36 it should get even better, as we'll (hopefully) have direct scan-out / "unredirect" by then. Unfortunately it's likely that the perceived performance is still a bit worse on Wayland as the cursor is not yet updated out of main thread. So under load things can feel less responsible (although the game may update with the same FPS count). Well, actually it is less responsible.

                    Comment


                    • #30
                      For SDL1 games one can use SDL1 -> SDL2 wrappers like https://hg.libsdl.org/sdl12-compat/ or https://github.com/MrAlert/sdlcl

                      Pretty much every SDL2 game should run in Wayland. Maybe you have to delete/replace the SDL2 library that comes with the game but everything I tried just works.
                      -MacNuke-
                      Senior Member
                      Last edited by -MacNuke-; 29 October 2019, 06:05 AM.

                      Comment

                      Working...
                      X