hashlink
hashlink copied to clipboard
[SDL] Precision of mouseX/mouseY in Touch events
https://github.com/HaxeFoundation/hashlink/blob/3767c47e42fd1f6b990b8c4e87e1c23ae825314b/libs/sdl/sdl.c#L187-L188
For some reason, the X/Y coords of Touch related events (down/up/move) are 0-100 based. This is incredibly low for any modern screen.
Is it possible to use actual screen coords or at least a much higher precision range here?
Is the input range 0-1 ? If yes then yes it should scaled by something like 65536 Maybe requires some changes on Heaps side as well.
Yes base value is 0-1 according to SDL api. Isn't it possible to match the actual context size, as expected for a mouseX/Y value?
I have no idea, it was originally contributed as part of native mobile support in #101 (ping @rtissera)
It's been increased to 10000 since then.