Skip to content

Reimplement wayland-cursor to be more lazy

Link Mauve requested to merge linkmauve/wayland:cursor-reimplementation into master

This Rust implementation is designed to be as lazy as possible, it does just enough of the work for each step of the API to complete. This lets it get a much lower memory usage (26,628 KiB → 22,792 KiB on start for a random GLFW demo) and also reducing its starting time to about one third of the previous time.

There are a few questions remaining:

  • How to integrate this in the build system? librsvg has a nice tutorial about autotools integration, but if we’re migrating to meson before this merges I would prefer to avoid having to do that.
  • What do we want to do about the existing C implementation? This MR keeps it and there is nothing preventing both from existing for some time.
  • The c_abi module is quite brittle, it’s my first time exposing a C ABI and I’m sure there are better ways to do some of the things, so I’d like to have more eyes on that.

Fixes #109.

Edited by Link Mauve

Merge request reports