https://bugs.winehq.org/show_bug.cgi?id=48252
Bug ID: 48252 Summary: Input is dropped while drawing perfectly-vertical lines if tablet is set to 'Relative' mode Product: Wine Version: 4.21 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: wintab32 Assignee: wine-bugs@winehq.org Reporter: layif52204@amail1.com Distribution: ArchLinux
Hello there, I'm having issues in Clip Studio Paint where if the tablet is set to relative mode input is completely lost if the lines are perfectly vertical.
I've tried this in both Wine 4.21, and Wine 4.21 staging, while in staging the terminal outputs "002c:fixme:wintab32:motion_event Negative orAltitude detected" for each motion event.
This issue has existed for a number of Wine releases, likely dating back even further than wine 3.x, terminal output however has been somewhat new.
Video of the problem, recorded using Clip Studio Paint Pro v1.9.4 running on the latest Wine 4.21 staging from Manjaro repository: https://streamable.com/jxi6u
A download for Clip Studio Paint (v1.9.5) can be found at: https://www.clipstudio.net/en/dl
(Although recorded in v1.9.4, the issue has been present for a number of releases, and is still present in the latest release v1.9.5.)
https://bugs.winehq.org/show_bug.cgi?id=48252
amiire layif52204@amail1.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|wintab32 |-unknown CC| |leslie_alistair@hotmail.com | |, z.figura12@gmail.com Product|Wine |Wine-staging
https://bugs.winehq.org/show_bug.cgi?id=48252
amiire layif52204@amail1.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|-unknown |wintab32 Product|Wine-staging |Wine
https://bugs.winehq.org/show_bug.cgi?id=48252
--- Comment #1 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- Can you please attach a +wintab32 log?
https://bugs.winehq.org/show_bug.cgi?id=48252
Alistair Leslie-Hughes leslie_alistair@hotmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- URL| |https://www.clipstudio.net/ | |en/dl Keywords| |download
--- Comment #2 from Alistair Leslie-Hughes leslie_alistair@hotmail.com --- I've just updated the patchset in staging to just print a FIXME and not fail when a Negative orAltitude is detected. I'm not expect this to fix the issue but at least it a starting point.
https://bugs.winehq.org/show_bug.cgi?id=48252
--- Comment #3 from amiire layif52204@amail1.com --- Created attachment 65954 --> https://bugs.winehq.org/attachment.cgi?id=65954 output log
https://bugs.winehq.org/show_bug.cgi?id=48252
--- Comment #4 from amiire layif52204@amail1.com --- (In reply to Alistair Leslie-Hughes from comment #1)
Can you please attach a +wintab32 log?
Sure thing.
https://bugs.winehq.org/show_bug.cgi?id=48252
--- Comment #5 from amiire layif52204@amail1.com --- Created attachment 65963 --> https://bugs.winehq.org/attachment.cgi?id=65963 +wintab32 log
Here is actual the +wintab32 log, my apologies.
Also perhaps its of some significance to mention my tablet is has a rotation configuration of 'half' (so it is upside down).
https://bugs.winehq.org/show_bug.cgi?id=48252
--- Comment #6 from amiire layif52204@amail1.com --- The mouse no longer lags in the latest release, however lines aren't drawn during this period. I'll link a recording of how it looks soon.
https://bugs.winehq.org/show_bug.cgi?id=48252
beknonam@yevme.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |beknonam@yevme.com
--- Comment #7 from beknonam@yevme.com --- Created attachment 70457 --> https://bugs.winehq.org/attachment.cgi?id=70457 fix for negative orAltitude
The XEvents' axis_data array only updates values that have changed, and sets its size according to the maximum index of the changed axis +1.
For instance; the pointer's X value corresponds to the indice [0], the Y [1], the NormalPressure [2], and so on. If only the X value of the pointer changes then the reported size of the axis_data will be 1, axis_data[0] will hold the new X value of the pointer, and any indice after [0] will have stale data from the previous frame.
However if only the NormalPressure changes, then the reported size of the axis_data will be 3 and axis_data[2] will report the new NormalPressure, however the indices for the X and Y in the axis_data will be left unaltered as that axis has reported no change. Previously, the struct was cleared before use at each motion_event, button_event, and proximity_event, due to this whenever there was a change in a higher axis, but the the lower axis, such as X or Y were unchanged the pointer would erratically teleport to the top-left corner (0,0).
To fix this bug I added moved the memsets to the X11DRV_AttachEventQueueToTablet so that the struct would only be cleared once after initalization and not after each event callback, allowing for the previous positions to be retained when only the pressure, or Y-axis changes.
Furthermore I added simple checks to only update axis that were changed, so that axis with an index greater than the reported axis_data size will not modified. This fixes the the negative OrAltitude bug.