Proton: Unusual, undesirable interaction between Wacom devices and Proton makes some games unplayable.

Created on 23 Oct 2019  路  16Comments  路  Source: ValveSoftware/Proton

Connected Wacom devices are triggering strange spurious input in some Proton games. On the menu screen of affected games, it acts similarly to holding the down arrow, endlessly scrolling down if the pen is not near the device. Placing the pen slightly above the middle of the device so it can control cursor movement without dragging causes the spurious motion to stop; hovering over the top third or so of the screen causes the motion to reverse direction and move up instead of down; and hovering over the bottom third resumes the initial downward motion.

Disabling all relevant Wacom input devices via xinput does not fix this behaviour: Proton continues to react to the device and pen location despite being disabled and unusable for input.
Changing input mode from Absolute to Relative (xsetwacom --set $device_name Mode Relative) also has no effect. Strange behaviour stops immediately after unplugging the device.

Tested with an Intuos 4 Large and a Cintiq 16 (not pro), behaviour is same with both devices.

I don't have many Proton games installed, so the game sample size is small, but so far The King of Fighters XIII and Soul Calibur VI are both affected by this, but Bloodstained: Ritual of the Night is not.

Currently on Steam's beta channel, affects every Proton version I've tried since launch day.

Most helpful comment

All 16 comments

Oh nice. I hadn't loaded an affected game for a while so I sort of forgot it existed, meant to report it a while back. Nice coincidence that someone started working on it around the same time I fire up an affected game again. :) Thanks for the info.

Hey, I included those commits in 4.11-8, but I'm pretty sure they won't actually fix your problem. Giving this a closer look is high on my list for the next release. Thanks for your patience.

I tested with 4.11-8 and you're correct, the commits did not fix the odd behaviour. I understand this sort of thing takes time, though, so I'm not bothered by it taking a bit to fix. I use a Windows VM with GPU passthrough for anything that Proton doesn't handle well, so this sort of thing isn't much of an issue for me, I just boot the VM and play that way until it works.

When I noticed it was still a problem when I came back to SC6 after a break, I reported it to hopefully help get it fixed for others, not me, since it's weird and the source might not be apparent to others encountering similar issues.

Regardless of time taken to deal with it, your effort is appreciated.

These wouldn't fix the issue since proton only uses joystick_sdl. Having a quick look and I think the short term fix would to be use environment variable SDL_GAMECONTROLLER_IGNORE_DEVICES, to ignore the device in question.

Hey @Ilazki sorry I haven't gotten around to working on this more quickly. Unfortunately we weren't able to reproduce this with the tablet we have in the office. Are you willing to gather some logs for me to look at? This might become a little involved, but hopefully we can come out the other side with this fixed.

First we need to gather a log with these debug channels:

+timestamp,+pid,+tid,+seh,+debugstr,+loaddll,+dinput,+xinput,+rawinput,+plugplay,+hid,+hidp

You can either copy Proton 5.0/user_settings.sample.py to Proton 5.0/user_settings.py and modify the file to include those channels on the WINEDEBUG line, or input it into the Launch Options dialog for your game:

WINEDEBUG=+timestamp,+pid,+tid,+seh,+debugstr,+loaddll,+dinput,+xinput,+rawinput,+plugplay,+hid,+hidp %command%

Then, run your game and reproduce the problem briefly. Exit the game, compress the log file (e.g. gzip ~/steam-1234.log), upload it here, and I'll take a look.

Note that logging does impact performance, so it isn't something you want to have enabled when playing games normally.

Hey @Ilazki sorry I haven't gotten around to working on this more quickly.

No problem, it's not a huge issue for me because I use a mix of native, Proton, and a VM with GPU passthrough, so if one doesn't work I just use another. I reported it to help out, not help myself.

Unfortunately we weren't able to reproduce this with the tablet we have in the office.

Out of curiosity, does that tablet lack tilt support? I was discussing this recently with some people that don't run into the same problem and they all had devices lacking tilt while both of my devices support it.

Are you willing to gather some logs for me to look at? This might become a little involved, but hopefully we can come out the other side with this fixed.

Sure. I can't do it right now but I will when I have a chance..

Here you go, log file: steam-544750.log.gz

I ran Soul Calibur VI just long enough to get to the title screen, watched the game constantly respond to up arrow (or pad) events on the main menu, and then played a "minigame" where I tried to time it so I could exit the game by pressing space when the exit option was selected.

The only input I provided to the game was spacebar mashing to get to the main menu, a couple failed attempts at exiting, and escape key to return to the main menu when I hit the wrong entry.

@Ilazki Thanks. I attached a tarball here that includes an executable. Can you run this executable with your tablet plugged in and copy the output here? It will tell us what "type" of joystick this device is, which we might be able to use to ignore it.

(I've also included the source if you'd rather build it yourself.)

sdl_test.tar.gz

(I've also included the source if you'd rather build it yourself.)

Thanks for that. Anyway, I also connected my Intuos 4 before running it, because both devices cause the same problem, though it was less troublesome with the Intuos because it was easier to disconnect when not in use compared to the pen display.

> ./sdl_test
js 0 (Wacom Intuos4 6x9 Pen): SDL_JOYSTICK_TYPE_UNKNOWN
js 1 (Wacom Intuos4 6x9 Pad): SDL_JOYSTICK_TYPE_UNKNOWN
js 2 (Wacom Cintiq 16 Pen): SDL_JOYSTICK_TYPE_UNKNOWN

Hmm, looks like SDL2 just has a hard-coded list of devices that are not actually joysticks. https://hg.libsdl.org/SDL/file/bd45c7649f7b/src/joystick/SDL_joystick.c#l1964

That's dissatisfying... Your joystick isn't listed there, so SDL lets it through and reports it as a joystick. We can update the blacklist in SDL (and/or add one in Proton) but that obviously won't fix future devices. I'll think on this a bit and see if I can figure something out with upstream SDL.

(In the meantime, I think @alesliehughes's suggestion from earlier in this thread should be an easier workaround for you than unplugging the device.)

@Ilazki I've implemented a blacklist for Wacom devices. I've attached modules here that you can extract into your existing Proton installation to try it out:

cd Proton 5.0/dist/ tar -xf ~/Downloads/dinput8.tar.gz

It will overwrite two existing dinput8 files. I'm hopeful this will fix the problem for Soul Calibur 6. (It may not fix other games, as this will only fix games that use dinput8. I have fixes for other parts of Wine too, which will be included when this is released.)

dinput8.tar.gz

Patch: 0001-winebus-dinput-Ignore-some-joysticks-that-SDL-report.txt

Hmm, looks like SDL2 just has a hard-coded list of devices that are not actually joysticks. [...] That's dissatisfying... Your joystick isn't listed there, so SDL lets it through and reports it as a joystick.

Wow, that list of ignored Wacom devices is insanely outdated and incomplete, and even the URL in the comment is dead. (Working URL.) I wonder if they're only adding devices as problems are reported, or if most newer tablets are fine for some reason. (The Cintiq 16 was released about a year ago, so at least some newer ones still have problems.)

I've attached modules here that you can extract into your existing Proton installation to try it out

Thanks, I'll try it later when I have a chance.

Yep, ignores the Cintiq just fine.

Hi @Ilazki, Proton 5.0-6 was just released and contains the blacklist for Wacom devices. OK to close this bug?

Just did a Proton update and everything still worked, so I'll close this now. Sorry you guys had to deal with this; the joys of (sort of) niche hardware :)

Thanks a bunch!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

juppso picture juppso  路  3Comments

shaphanpena1 picture shaphanpena1  路  3Comments

Dakunier picture Dakunier  路  3Comments

ghost picture ghost  路  3Comments

ghost picture ghost  路  3Comments