Fuzzyzilla / octotablet

High-level Tablet/Stylus API for Rust
https://crates.io/crates/octotablet
MIT License
14 stars 2 forks source link

Failed to acquire connection: handle doesn't contain a supported display type #7

Closed MathiasYde closed 2 months ago

MathiasYde commented 2 months ago

Hello, the example project compiles and runs on my Pop!_OS computer, but it's seemingly incompatible with my Wacom 16" tablet (which should be supported according to the readme)

Screenshot from 2024-04-18 21-03-26

inxi dump

System
  Host: pop-os Kernel: 6.8.0-76060800daily20240311-generic x86_64 bits: 64
    Desktop: GNOME 42.5 Distro: Pop!_OS 22.04 LTS
Fuzzyzilla commented 2 months ago

Hello!

Currently, octotablet supports Wayland desktops, but not Xorg. Pop_OS only provides Xorg support - although it seems possible to enable wayland - at current, the wayland implementation is a bit buggy under Pop_OS so it is not made available by default.

Xorg support is top of my priorities for this crate! Unfortunately I have not had much time to implement it, but it still is very much a goal as I understand a large portion of the desktop Linux community still uses it.

Thank you for the report!

Fuzzyzilla commented 2 months ago

I suppose I should only mark this as closed when it's actually fixed, huh? :P Sorry bout that.

MathiasYde commented 2 months ago

Haha that's okay. To be honest, I don't really have much Linux literacy so terms like Wayland and Xorg fly right over my head. I've recently switched to Pop!_OS after Microsoft's astrocious plan to incorporate AI and ads into Windows.

Are you currently working on the Xorg implementation for this crate?

Fuzzyzilla commented 2 months ago

Ah, I see! Wayland and Xorg are the two primary options for the protocol that apps use to communicate with your system to do things like show windows, accept keyboard/mouse input, etc - and importantly here, stylus input goes through those channels too. X11 is a much much older standard and has stagnated quite a bit (nearing 40 years now!) so it was not my first goal for this crate, but it is still widespread due to some major tradeoffs between the two. As far as I know, the Pop_OS team is working very hard to implement the Wayland protocol - coming soon, but not yet!

After your issue, I did take some time to explore an X11 implementation in a separate repository. My research is far from complete, but at the very least have it listing out connected tablets and their capabilities. Seems that I've hit a bit of a wall on that attempt though, so I'm still exploring! Perhaps I will open a tracking issue to keep a log of my progress.

MathiasYde commented 2 months ago

Oh wow, I see the favor of Wayland over Xorg. I followed this StackOverflow answer and enabled Wayland on my Pop!_OS machine which made the examples work (The eframe-viewer example is so cool), I had some issues with my displays but a simple reboot fixed it :)

I think I just assumed that I already had enabled Wayland since I saw many crates with similar names while compiling Rust code, and Blender/Krita also recognized my Wacom tablet on Xorg (But I suppose they also have a bit more man-power than just you on this repo)

Fuzzyzilla commented 2 months ago

Yay!! I am glad it is working for you! I had a lot of fun with that egui-viewer example, I may have gone a bit too far with the fanciness :P

I have moved discussion of X11 implementation over to #10.