Skip to content

Touch location and pen location different after zooming / screen rotation #125

@golemusu

Description

@golemusu

Checklist

  • I can reproduce the bug with the latest version given here.
  • I made sure that there are no existing issues - open or closed - to which I could contribute my information.
  • I made sure that there are no existing discussions - open or closed - to which I could contribute my information.
  • I have read the FAQs inside the app (Menu -> About -> FAQs) and my problem isn't listed.
  • I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • This issue contains only one bug.
  • I have read and understood the contribution guidelines.

Affected app version

1.2.0

Affected Android/Custom ROM version

OxygenOS (Android) 14

Affected device model

Oneplus Pad Go

How did you install the app?

F-Droid / IzzyOnDroid

Steps to reproduce the bug

sometimes paint goes to "draw to wrong place" bug mode. This happens typically after first drawing something with pencil and then zooming out with 2 fingers. Also I now noticed that the bug appears sometimes when I turn the device from portrait to landscape or back (auto rotate android UI is enabled).

When bug is present if I touch pixel 300,300 and pull it to pixel 600,600, the actual line on the screen could appear to pixels 600,100 - 900,400.

The length of error vector varies, sometimes it could be 25% of the length of display and sometimes only 2-5%

Getting rid of the bug I have to go to settings - apps - Fossify Paint - force stop.

Device is Oneplus Pad Go (Mediatek G99 soc, 8GB RAM, 2480 x 1720 resolution (1.4 aspect ratio), 11 inch screen).

I did just 5min test with my phone (galaxy S21fe, 2300ish x 1080 res) and in that time I was unable to reproduce it.

Worth noting is that this tablet has unusual aspect ratio and resolution for androids (typical android tablets are 1.6 aspect ratio and phones are over 2). Nevertheless IMO this is best aspect ratio and e.g. iPad aspect ratios are at same ballpark (1.33 - 1.5).

With tablet it is much more common to rotate the device than with phones (IMO) so program should take this into account.

The bug does not appear every time, I am not sure what factors cause it. But if you take a tablet, start drawing, doing lot of 2 finger pinch zooms in and out and drawing in different zooming factors, sometimes panning (moving 2 fingers to any directions), and then rotating the device so that auto-rotate happens you have high change of running into this bug.

I suspect that the bug is on the algorithm which translates touch coordinate to drawn pixel coordinate.

Expected behavior

pen location remains in touch location

Actual behavior

pen location is different than touch location

Screenshots/Screen recordings

Here is link to screen recording of the bug (skip to 00:28 if you want to see it directly). I tried to attach it but was unable to do it so below is a nextcloud to the recording (h265)

https://nx76363.your-storageshare.de/s/AY8GA5gkaXkqzc4

Additional information

.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is not workingdevice/software specificIssues concerning devices with some specific hardware/softwareneeds reproductionCouldn't reproduce. More info or help is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions