Earlier quoted context omitted.
What exactly is insane here? That games/applications might want to draw custom cursors?
Any other system has a cursor hide feature that games/applications opt into. Everything else should have the compositor overlay the cursor This is particularly important because most applications aren't designed to render at monitor framerate, whereas games make an exception because they tend to be full screen applications & tend to render at a high framerate already
Improving cursor rendering on Wayland
31–40 of 134 posts
Re: Improving cursor rendering on Wayland
#32Re: Improving cursor rendering on Wayland
#33How are cursors stored and drawn on let's say macOS? Honest question, comparing with X is easy but not exactly state of the art.
TL;DR: it's integrated with the rest of Cocoa. macOS cursors are provided by an NSCursor class which can either be one of the standard cursor image or provided through an NSImage object, which supports a number of data types (among the usual pixel-based formats like PNG or JPEG also PDF), it looks like applications can also register their own data formats via a class called NSImageRep.
Re: Improving cursor rendering on Wayland
#34> In the beginning of wayland, and in the core design spec, it's the client's job to draw the cursor. I mean, it kind of makes sense, as some apps might want to draw a custom cursor (e.g. games) Wait what. That's even more insane than client-side decorations.
This allows the application to customize the cursor, which happens more frequently than you might expect, e.g. dragging and dropping a file changes the "cursor" to include the little preview of the file. So the client already needs to learn how to render cursor images to composite the cursor image on top of the DnD preview.
One of Wayland's original core philosophies is to share behavior by shared library, rather than by protocol, because social agreement is already required, and is way better for a community long-term. So there is also a libwayland-cursor library that allows you to load Xcursors, which allows the client to do all the compositing and customization it needs, while still supporting a standard.
zwp_cursor_shape makes sense for a basic client without too many needs, but it's not a great idea for a full toolkit, otherwise DnD dragging (or any other case that requires compositing cursor images) will show a different cursor.
Also, SVG for cursors is not really a great idea.
Re: Improving cursor rendering on Wayland
#35What is this config.hl file format? At first, I thought it’s hlc [0], but I couldn’t find confirmation in the git repo either. [0]: https://www.linode.com/docs/guides/introduction-to-hcl/
https://github.com/hyprwm/hyprcursor/blob/main/docs/MAKING_T...
Looking at the full description of the format, it includes the ability to use nested config sections with `{ ... }`, which has some obvious benefits for some use-cases. But for the complexity needed for defining cursors, I don't see the benefit of `.hl` over fdo `.desktop` configs. In fact, it looks like you could parse the hyprcursor `.hl` config files with a `.desktop` parser? Which might be more palatable for cross-desktop support?
Re: Improving cursor rendering on Wayland
#36The article essentially says--whether this is a good idea or not--that GTK is the one hold-out, which I wasn't really expecting as a punchline; why is GTK not implementing this?
Gnome are consistently the hold-out, and are the source of much drama and chagrin in Wayland.
Re: Improving cursor rendering on Wayland
#37> In the beginning of wayland, and in the core design spec, it's the client's job to draw the cursor. I mean, it kind of makes sense, as some apps might want to draw a custom cursor (e.g. games) Wait what. That's even more insane than client-side decorations.
Of course, because this is Wayland, one good idea suffers due to coexisting with other independently good ideas. The minds behind Wayland didn't want the protocol to ossify like X11 did, so they made extensions essential. If a given functionality doesn't need to be core, it's an extension.
Both great ideas in isolation, yet now, as a result, Wayland has trapped its ecosystem in a half-assed state of completeness. The one saving grace is that, unlike X11, things will actually improve over time as the gaps get filled in and older applications age out of the ecosystem.
Re: Improving cursor rendering on Wayland
#38xorg and it's problems is so funny
It's a Wayland problem if it is really problem at all though. The author complains that XCursor themes take too much space on disk (They will live uncompressed in VRAM anyways). Considering we are talking about Megabytes in the age of Terabytes HDDs, as long as you don't want to install thousands of XCursor themes on the same machine this is really a non-issue.
Most distributions still use a "Live CD" format, actually a "Live DVD" nowadays (with a few hacks to make it also work as a USB pen drive image), for their installers, and that limits the installation image size (which also includes enough packages for an offline install of a desktop environment) to a bit more than 4GB (they fit into a common 8GB USB pen drive). So it being the "age of Terabyte HDDs" does not matter, for packages expected to be installed on a normal desktop system.
Re: Improving cursor rendering on Wayland
#39The article essentially says--whether this is a good idea or not--that GTK is the one hold-out, which I wasn't really expecting as a punchline; why is GTK not implementing this?
Gnome and Wayland (among other things) are the way they are, in part, to make running anything other than a standard-package-selection Red Hat unappealing to folks who might pay for Linux (enterprise). It’s good for them if their stuff’s a bit broken if you use other distros, or configs/software they don’t want to support, and if they cause integration pain and extra work for other distros. Or if that’s not the reaso…
Re: Improving cursor rendering on Wayland
#40Earlier quoted context omitted.
I think it's just a standard corporate insularness. Devs being paid to work on the software by the corporation view outsiders as a nuisance and certainly don't like outsiders giving them more work to do. They'd rather find justifications to remove features reinvent old systems to "reduce legacy cruft" (make their jobs easier.). Basically, it all makes sense if you assume standard commercial developer motivations.
Or even better - remove features and then let someone else implement them.