logo

drewdevault.com

[mirror] blog and personal website of Drew DeVault git clone https://hacktivis.me/git/mirror/drewdevault.com.git

Future-of-sway.md (4592B)


  1. ---
  2. date: 2017-10-09
  3. layout: post
  4. title: "The future of Wayland, and sway's role in it"
  5. tags: [wayland, sway, wlroots, announcement]
  6. ---
  7. Today I've released sway
  8. [0.15-rc1](https://github.com/swaywm/sway/releases/tag/0.15-rc1), the first
  9. release candidate for the final 0.x release of sway. That's right - after sway
  10. 0.15 will be sway 1.0. After today, no new features are being added to sway
  11. until we complete the migration to our new plumbing library,
  12. [wlroots](https://github.com/swaywm/wlroots). This has been a long time
  13. coming, and I would love to introduce you to wlroots and tell you what to expect
  14. from sway 1.0.
  15. <small class="text-muted"><a href="https://github.com/swaywm/sway">Sway</a> is
  16. a tiling Wayland compositor, if you didn't know.</small>
  17. Before you can understand what wlroots is, you have to understand its
  18. predecessor: [wlc](https://github.com/Cloudef/wlc). The role of wlc is to manage
  19. a number of low-level plumbing components of a Wayland compositor. It
  20. essentially abstracts most of the hard work of Wayland compositing away from the
  21. compositor itself. It manages:
  22. - The EGL (OpenGL) context
  23. - DRM (display) resources
  24. - libinput resources
  25. - Rendering windows to the display
  26. - Communicating with Wayland clients
  27. - Xwayland (X11) support
  28. It does a few other things, but these are the most important. When sway wants to
  29. render a window, it will be told about its existence through a hook from wlc.
  30. We'll tell wlc where to put it and it will be rendered there. Most of the heavy
  31. lifting has been handled by wlc, and this has allowed us to develop sway into a
  32. powerful Wayland compositor very quickly.
  33. However, wlc has some limitations, ones that sway has been hitting more and more
  34. often in the past several months. To address these limitations, we've been
  35. working very hard on a replacement for wlc called wlroots. The relationship
  36. between wlc and wlroots is similar to the relationship between Pango and
  37. Harfbuzz - wlroots is much more powerful, but at the cost of putting a lot more
  38. work on the shoulders of sway. By replacing wlc, we can customize the behavior
  39. of the low level components of our system.
  40. I'm happy to announce that development on wlroots has been spectacular. Like
  41. libweston has Weston itself, wlroots has a reference compositor called Rootston -
  42. a simple floating compositor that lets us test and demonstrate the features of
  43. wlroots. It is from this compositor that I write this blog post today. The most
  44. difficult of our goals are behind us with wlroots, and we're now beginning to
  45. plan the integration of wlroots and sway.
  46. All of this work has been possible thanks to a contingent of highly motivated
  47. contributors who have done huge amounts of work for wlroots, writing and
  48. maintaining entire subsystems far faster than I could have done it alone. I
  49. really cannot overstate the importance of these contributors. Thanks to their
  50. contributions, most of my work is in organizing development and merging pull
  51. requests. From the bottom of my heart, [thank
  52. you](https://github.com/swaywm/wlroots/graphs/contributors).
  53. And for all of this hard work, what are we going to get? Well, for some time
  54. now, there have been many features requests in sway that we could not address,
  55. and many long-standing bugs we could not fix. Thanks to wlroots, we can see many
  56. of these addressed within the next few months. Here are some of the things you
  57. can expect from the union of wlroots and sway:
  58. - Rotated displays
  59. - Touchscreen bindings
  60. - Drawing tablet support
  61. - Mouse capture for games
  62. - Fractional display scaling
  63. - Display port daisy chaining
  64. - Multi-GPU support
  65. Some of these features are unique to sway even among Wayland *and* Xorg
  66. desktops combined! Others, like output rotation, have been requested by our
  67. users for a long time. I'm looking forward to the several dozen long-open GitHub
  68. issues that will be closed in the next couple of months. This is just the
  69. beginning, too - wlroots is such a radical change that I can't even begin to
  70. imagine all of the features we're going to be able to build.
  71. We're sharing these improvements with the greater Wayland community, too.
  72. wlroots is a platform upon which we intend to develop and promote open standards
  73. that will unify the extensibility of all Wayland desktops. We've also been
  74. working with other Wayland compositors, notably
  75. [way-cooler](https://github.com/way-cooler/way-cooler), which are preparing to
  76. move their own codebases to a wlroots-based solution.
  77. My goal is to ship sway 1.0 before the end of the year. These are exciting times
  78. for Wayland, and I hope you're looking forward to it.