Skip to content

Touchscreen, wrong finger motion coordinates when using kmsdrm backend #14947

@jalih

Description

@jalih

I noticed there is a problem with touchscreen finger motion coordinates on my system when using the kmsdrm backend. I have a touchscreen using 1024x600 resolution, SDL3 currently reports touchscreen max coordinates as:

x: 15.98462, y: 5.48409

I noticed evtest utility reports my touchscreen max values as:

Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 512
Min 0
Max 65535
Event code 1 (ABS_Y)
Value 259
Min 0
Max 65535

A little bit of math gives us:

65535 / 1024 * 15.98462 = 1023.000
65535 / 600 * 5.48409 = 598.997

Should SDL3 do this normalization or mapping of coordinates to the actual screen resolution?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions