11 ms·
Wayland on Wine: A First Update
- chaorace 6y agotl;dr: Right now, Wine doesn't work on Wayland compositors (this was news to me!). If you're using Wine on Wayland today, it's running through XWayland, which is essentially a X11 => Wayland shim. This article is about the new RFC to implement native Wayland in Wine, which would eliminate the need for such a shim.
- tremon 6y agoShouldn't the article be called "Wine on Wayland" instead of "Wayland on Wine" then? I was really confused by the headline.
- loudmax 6y agoAgreed. This naming approach reminds me very much of the Windows Subsystem for Linux.
- ravenstine 6y agoThey just want their name to come first. ;) Besides, it has a nice ring to it! wink wink
- deleted 6y ago[deleted]
- TazeTSchnitzel 6y agoI think that one's motivated by trademark rules.
- pzone 6y agoIt’s a typo, the original article is correct
- exciteabletom 6y agoTo me that name makes sense. It is a Windows Subsystem that adds support for Linux
- cptnapalm 6y agoTo myself, Windows Subsystem for Linux sounded like a Windows subsystem for Linux.
- mfilion 6y agoUpdated :)
- scaladev 6y agoThis is really tangential to the topic, but does anybody know of any decent performance comparisons between Xwayland and plain X? I saw some talks made by Xorg developers (Keith Packard and others) from ~2012 or so, where they speculated that running Xwayland should be more performant than plain X due to less memory copying and less context switches, but could not find actual tests (and am too incompetent to do it myself.)
- shmerl 6y agoI tested The Witcher 3 in the KDE Plasma Wayland session (Wine / XWayalnd, dxvk, radv). I didn't notice any performance degradation or major difference, so I'd say it works very well for games at least. The only gotcha was the need to use 3 backbuffers for Vulkan (in dxvk config), otherwise framerate was capped at monitor refresh rate by KWin.
- thayne 6y ago> Right now, Wine doesn't work on Wayland compositors (this was news to me!) No, it doesn't work natively on wayland. It does work using Xwayland, as do many other applications that haven't been ported to wayland. There are some cases where Xwayland doesn't work, though, and those will likely be the toughest things to deal with when adding wayland support as well. It's quite possible this will result in changes to wayland protocols.
- chaorace 6y agoDid... you stop reading my comment halfway through? I don't understand why you're correcting me with information that's literally in the following sentence.
- war1025 6y agoDoes anyone know if the terrible framerates in the different games are typical or just an artifact of the way they recorded the video? Maybe they were just demoing the resolution scaling stuff?
- vetinari 6y agoThe resolution scaling is done by the scan out engine, not by the GPU. At least on capable hardware, which should be basically anything you see today (maybe not on SBCs). It is also as fast as the scan-out is.
- mfilion 6y agoThe low FPS is an unfortunate effect of our capture setup on a not very powerful system. The FPS values we get when not capturing are normal (i.e., on par with Wine on X11).
- deleted 6y ago[deleted]
- sbisson 6y agoAs an aside it's interesting to note that Collabra are working with Microsoft on a Mesa 3D/Direct X bridge. With Wayland support coming to WSL 2, it's possible to speculate that this approach could also be used to bring a Wayland compositor to the Windows Remote Desktop for application window-level remote access to for WSL 2.
- ntauthority 6y agoThis has been claimed [1] to work via RAIL already - the 'Remote Applications Integrated Locally' layer for RemoteApp/RDP. [1]: https://www.mail-archive.com/dri-devel@lists.freedesktop.org/msg310189.html https://www.mail-archive.com/dri-devel@lists.freedesktop.org...
- ognarb 6y agoReading this mailing list thread, I'm really not a fan of 'Linux' application that only work on WSL2. This feels wrong and some would qualify it as the expand part in EEE (embrace, expand, extinguish).
- spijdar 6y agoBut ... but that's not what the email says, at least from a casual reading. > We would like to build it such that in theory any Wayland compositor could add support for this mode of operation if they want to remote application to a Windows host (over the network, or on the same box). I'm not really in the state of mind to fully parse the full email chain, but it sounds like they want the ability to extend Wayland to forward a wayland window/application over RDP to an RDP client. This isn't really WSL2 specific, and could be used to forward applications from a dedicated Linux machine to a Windows client, or maybe even to another Linux host running FreeRDP! I know the idea of using RDP at all isn't very sexy on Linux, but FreeRDP is nice, and you don't need to use windows at all to benefit from it. IMO it's pretty nice for when you need a detached session, especially per user sessions or multi sessions per user. Definitely better than VNC, again IMO.
- viraptor 6y agoThe display mode faking via scaling would work for resolution, but that sounds like it wouldn't support other cases, like refresh rate, and HDR, right? Also they didn't mention cases where the display has different capabilities at different resolutions (like 4k@30Hz and 1080@120Hz)
- arghwhat 6y agoHDR is not yet supported, but is to be handled through upcoming color management protocols. Lowering the refresh rate of the display isn't really useful. The refresh rate of the monitor only acts as an upper limit on visual updates - you can always just skip frames at no cost outside display cable bandwidth utilization if you don't want to update. Note: VRR is unrelated to modesets, works through an entirely different mechanism, and is supported by a few compositors.
- VRay 6y ago> Lowering the refresh rate of the display isn't really useful woah woah woah there, what about if you have a panning camera shot in a movie at 24 FPS and try to watch that movie on a 60 hz display? You'll get tiny micro-stutters AKA "judder". They're subtle but if you can notice them, they ruin your moviewatching experience every time
- arghwhat 6y agoDo you modeset your monitor to 24Hz when you watch a movie or a video? Do you remember to change between 24 Hz and 29.97 Hz? The solution to this is higher refresh rate and/or VRR. VRR would allow you to sync to any needed timing (regardless of VRR range, as multiples of fps are fine), dynamically, with no need to modeset to fixed supported refresh rates. 120Hz not only happens to be a multiple of both 24 and 30, but judder from such low framerate input becomes irrelevant at these rates, with VRR instead serving high-framerate content that is slightly out of phase.
- cycloptic 6y ago
- shmerl 6y agoNice progress. Still waiting for KWin to support adaptive sync in the Wayland session, then switching to it will finally be a good idea.
- temac 6y ago> Still waiting for KWin to support adaptive sync in the Wayland session I'm still horrified by the coupling with each WM or DE that need to reimplement (or use a lib, but that's as interesting as noting that you could reimplement an HTTP server in each high level app by using an HTTP server lib...) all the features of the graphics server. Are there other examples of systems doing that for their graphic stack, particularly at this level? It feels wrong. It feels almost as wrong as it felt with BeOS depending on the G++ 2.95 ABI for its platform interfaces...
- lrossi 6y agoYou can add client side decorations to the list. It feels wrong because it is.
- cycloptic 6y agoIt's not wrong, it was done on purpose specifically because each DE wanted to have the flexibility from using their own graphics server. In 2021 I don't believe client-side decorations are something anyone can avoid, on any platform.
- account42 6y agoYou can absolutely avoid client side decorations on X11. Anything that cannot provide that is not a functional X11 replacement.
- Blikkentrekker 6y agoThe last time I checked on this situation, the Wine developers said they had indefinitely halted any plans for a Wayland port and not so much for the graphical reasons that this article suggests but the windowing a.p.i reasons. — so what changed in this regard? Can this project actually render Windows windows on Wine or is it only for fullscreen games?
- sho_hn 6y agoWhat changed is that the Wayland world keeps evolving, and things aren't always as dramatic as they first appear. Bridging the windowing semantics is difficult indeed as the Wayland approach doesn't let clients introspect the windowing system or absolutely position themselves, but it doesn't mean you can't get quite far with the excellent relative positioning provided by the xdg-shell/xdg-popup protocols, for example. The video in the article demonstrates Notepad and other windowed apps.
- pantalaimon 6y agoWell, wine developers are still skeptical https://www.winehq.org/pipermail/wine-devel/2021-February/181338.html https://www.winehq.org/pipermail/wine-devel/2021-February/18...
- Blikkentrekker 6y agoThat is a single Wine staging developer, however., not “wine developers”. That having been said, I share some of the concerns that Wayland is pushed, not as an alternative to X11 but as a replacement that many powerful players insist must and shall replace X11, all the while lacking many features that X11 has and that are used.
- bluGill 6y agoWayland is pushed because nobody is maintaining X11, the people who used to maintain X11 are now working on wayland. In short your choice is push wayland everywhere, or fund a new group of people to maintain X11. For the later I have little confidence in one person alone making significant progress, but if you want to prove me wrong - well good luck. I am betting on wayland long term, though I still have X11 a lot of places.
- forgotmypw17 6y agoI posted an Ask looking for answers on why X is suddenly "abandonware" while still-green Wayland is promoted as its replacement: https://news.ycombinator.com/item?id=26176037 https://news.ycombinator.com/item?id=26176037 It seems like the primary reason is that X has been abandoned by its developers in favor of Wayland.
- stelonix 6y agoWish I had seen that post of yours then. In short, X11 devs no longer wanted to maintain a huge codebase and decided to restart from scratch, thus, Wayland was born. The recent push toward Wayland adoption and "X IS DEAD LOL" behavior seems to be because KDE and GNOME adopted Wayland, while GNOME was adopted as default DE on Ubuntu. GNOME has an agenda to spread Wayland everywhere and since they're now in the most popular distro, you'll hear more and more that X11 in insecure, abandonware, bloated etc. If you do check X's codebase though, you'll notice it's very well written and completely maintainable. As an example, people often say you can fake input on X and therefore it's insecure, but fake input on X (XTEST) sets a boolean send_event that the receiving application can check to see if the event was sent from another application. Most apps ignore that, but Wine drops any event marked as send_event. I do not like this solution. Instead, inter-process access control lists could solve this easily and would not be hard to implement. Yet, some people think throwing 30 years of solid codebase down the toilet and pushing an inferior product is a better solution. Those people have no idea about X programming or its internals and are just echoing a mantra.
- cycloptic 6y agoPlease continue hacking on X if that's your fancy, I agree that the codebase is fine as far as legacy codebases go, the real problem is that the protocol itself has issues and that can't really be changed without breaking backwards compatibility or breaking ABI in xlib. Adding yet another security policy to the X server might fix some issues people have, it unfortunately won't fix all the other problems.
- stelonix 6y ago
- forgotmypw17 6y agoDoes anyone else get the same feel from Wayland as from WebExtensions? That is, being forced into a new system with less functionality while these shortcomings are swept under the rug with "we'll fix it later" and "nobody uses that" excuses?
- away_throw 6y agoI have yet to experience this. Granted XWayland makes any utilities not running in Wayland work perfectly for me. The only issues that I have ran into were because of screen-sharing not being supported by Electron. OBS works perfectly though. However, keep in mind that I use sway. I've heard horror stories from KDE and Gnome running on Wayland, but, as far as I know, this is because they apparently have terrible implementations. The benefits for me are the lack of screen tearing and Wayland just feels smoother.
- thayne 6y agoYes and no. I get a bit of that from wayland overall, but I use sway, and wlroots is actually really good about making protocols for missing functionality (and proposing them as standards).
- minitech 6y ago> Does anyone else get the same feel from Wayland as from WebExtensions? Yes, in that it’s another much-needed security and architectural improvement. (Bootstrapped Firefox extensions were a huge pain to build.)
- forgotmypw17 6y agoAny thoughts on WebExtensions not providing even a small fraction of the functionality of XUL?
- stelonix 6y agoYes, especially since X11 code isn't badly written. It gives me the feeling X devs were fed up with a huge codebase and wanted to write something new and shiny, albeit with 10% of features, pushing the maintenance burden downstream. The Wayland evangelists touting it as desktop-ready and no-true-scottsman'ing any critique also smells fishy. What Wayland did bring was more fragmentation. And yes, their attitude toward missing features is the same as GNOME's: WONTFIX parade 24/7.
- dalu 6y agoDog bitten by human or why the title twist?