230

Hello, yesterday I officially released Louvre v1.0.0, a C++ library designed for building Wayland compositors with a primary focus on ease of development. It provides a default method for handling protocols, input events, and rendering, which you can selectively and progressively override as required, allowing you to see a functional compositor from day 1.

It supports multi-GPU setups, multi-session (TTY switching), and offers various rendering options, including a scene and view system that automatically repaints only the damaged (changing) regions during a frame. Because it uses multiple threads, it can maintain a high FPS rate with v-sync enabled when rendering complex scenarios. In contrast, single-threaded compositors often experience a rapid drop in FPS, for example, from 60 to 30 fps, due to "dead times" while waiting for a screen vblank, leading to the skipping of frames.

The library is freely available, open source, thoroughly documented, includes examples, and features a detailed tutorial.

You can find it here: https://github.com/CuarzoSoftware/Louvre

I hope it proves useful for you. If you decide to use it and encounter any doubts or wish to contribute to its development, please don't hesitate to reach out.

Greetings!

you are viewing a single comment's thread
view the rest of the comments
[-] ijhoo@lemmy.ml 3 points 1 year ago

Do you plan to use vulkan wmi in any way?

Can xwayland be excluded?

[-] ehopperdietzel@lemmy.world 6 points 1 year ago* (last edited 1 year ago)

Honestly, I haven't explored Vulkan yet. I initially chose GLES 2.0 as the primary renderer to ensure compatibility with a wide range of hardware. Introducing Vulkan myself would be a time-consuming task unless I receive assistance.

Regarding XWayland, Louvre doesn't currently support it, so it's naturally excluded. Well, it technically can run in rootful mode, but that is somewhat pointless. To enable independent window management, I believe I would need to create a mini X server, a task I haven't tackled as of now.

[-] ijhoo@lemmy.ml 3 points 1 year ago* (last edited 1 year ago)

It looks very interesting.

I might be wrong, but it seems to me like Vulkan Support in hw is better than opengl:

  • amd since at least Polaris (there is a project to Bring vulkan to really old terrascale graphics, but is jot yet there)
  • Intel since idk ~~broadwell~~ Skylake
  • Nvidia proprietary for sure don't know since when and it seems that focus on nvk (new open source driver) is going to be on vulkan
  • android since version 7 - Eighty-five percent of active Android devices support Vulkan (this is better than android Version Rollout) https://developer.android.com/games/develop/use-vulkan
  • rpi, not sure which versions

Probably all of them have better Vulkan than opengl drivers (due to drivers being simpler). David Arlie rather quickly implemented first Vulkan driver for AMD once Vulkan was first released. Just in case you need incentive.

I was thinking of starting something similar as a learning exercise, but I'm really limited in time and not skilled as much in c++, so it would probably lead nowhere. Now I can just build on top - if I get any time for this, will come probably with questions.

Anyway, this idea was to make something modern. Without the legacy crap. Actual goals were:

  1. Vulkan only (move gfx API Info the future)
  2. no x/xwayland (most of the apps in newer toolkits already support Wayland, the others I'd rather avoid)
  3. Multithreaded
[-] ehopperdietzel@lemmy.world 3 points 1 year ago

Interesting, I don't recall where I read about Vulkan support still being experimental in many Mesa drivers; it might have been an outdated post. I'll look into it, and perhaps I'll decide to dive into learning Vulkan. Additionally, there are buffer-sharing mechanisms that already work smoothly with GLES, so I need to explore if the situation is similar for Vulkan. Thanks for your response, and if you have the time and inclination to help include it, feel free to do so! 😄

this post was submitted on 14 Nov 2023
230 points (99.1% liked)

Linux

48366 readers
1670 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS