libretro / desmume

DeSmuME is a Nintendo DS emulator
http://desmume.org
GNU General Public License v2.0
35 stars 33 forks source link

Touchscreen input mapped incorrectly in hybrid layout mode with hybrid layout scale set to 3 #34

Closed jdgleaver closed 6 years ago

jdgleaver commented 6 years ago

There seems to be a touchscreen input scaling/mapping bug under the following conditions:

With this setup, the mouse cursor is drawn correctly and can be moved to any part of the touchscreen, but all input is mapped to a rectangle 1/3 the size of the touchscreen in the top left corner. The following screenshot from 'Art Academy' most clearly demonstrates the problem:

art_academy

The dotted grey lines show where I clicked and dragged the mouse. The red 'paint' lines show where the input was registered.

The problem affects the most recent version of the core (commit 2085971) running under both Windows 7 (x64) and Linux (OpenSUSE Leap 43.3). The input mapping is correct if Hybrid Layout: Scale is set to 1.

bearoso commented 6 years ago

Ok, I think I fixed this, hopefully without introducing other issues.

jdgleaver commented 6 years ago

Thanks, that's brilliant - the input mapping works perfectly now!

(I tested all display modes/configurations and found no other issues, so all is well)