QT ignoring uinput touch inputs without ABS_MT_TRACKING_ID
-
I am having a very specific problem with qt 5:
If I start a simple qt program on my embedded device with a multi touch display and then inject inputs (via x11vnc -pipeinput UINPUT:touch... option), qt fully ignores these inputs.
With qt4 this used to work.After some debugging with "evtest", I found out that a press on the touchscreen sends not only x and y coordinates, but also ABS_MT_TRACKING_ID. The injected inputs do not send these parameters. However, I can use them to control other programs (ts_uinput) , so it is not a general problem.
Example evtest output touch screen:
Event: time 1674089640.781220, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1 Event: time 1674089640.781220, type 3 (EV_ABS), code 0 (ABS_X), value 26 Event: time 1674089640.781220, type 3 (EV_ABS), code 1 (ABS_Y), value 2 Event: time 1674089640.781220, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 26 Event: time 1674089640.781220, type 3 (EV_ABS), code 54 (ABS_MT_POSITION_Y), value 2 Event: time 1674089640.781220, type 3 (EV_ABS), code 57 (ABS_MT_TRACKING_ID), value 22 Event: time 1674089640.781220, -------------- SYN_REPORT ------------ Event: time 1674089640.897989, type 3 (EV_ABS), code 57 (ABS_MT_TRACKING_ID), value -1 Event: time 1674089640.897989, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 0 Event: time 1674089640.897989, -------------- SYN_REPORT ------------Example evtest output x11vnc inject:
Event: time 1674089607.895369, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 1 Event: time 1674089607.895369, type 3 (EV_ABS), code 0 (ABS_X), value 49 Event: time 1674089607.895369, type 3 (EV_ABS), code 1 (ABS_Y), value 12 Event: time 1674089607.895369, type 3 (EV_ABS), code 53 (ABS_MT_POSITION_X), value 49 Event: time 1674089607.895369, type 3 (EV_ABS), code 54 (ABS_MT_POSITION_Y), value 12 Event: time 1674089607.895369, -------------- SYN_REPORT ------------ Event: time 1674089610.170949, type 1 (EV_KEY), code 330 (BTN_TOUCH), value 0 Event: time 1674089610.170949, -------------- SYN_REPORT ------------I also modified x11vnc to also send messages with ABS_MT_TRACKING_ID - which are then picked up by QT.
It this a known behavior? Is there a known fix for this?
-
Hi and welcome to devnet,
The backend architecture has radically changed between Qt 4 and 5 so it might be something that got lost along the transition.
Which QPA are you using currently ?
-
Hi,
thank you so much for your reply.
I am using QT 5.15.8 (built with buildroot).
Does that answer your question? Sorry I am not really experienced with QT. -
No it does not, the QPA you selected might linuxfb, eglfs, etc. There is also the input plugin you are using which is likely evdev.
-
Ah sorry for the misunderstanding. I am using linuxfb and evdev for input.
-
Then I would check the bug report system to see if there's already something about it and if not open a new ticket.
-
Then I would check the bug report system to see if there's already something about it and if not open a new ticket.
@SGaist Thanks for pointing me in that direction. I did not find any related issues, so I opened a new ticket. Let's see if this is a bug or "feature".