I'm struggling with implementing a drawing feature...
# compose-desktop
m
I'm struggling with implementing a drawing feature in a compose desktop project. The drawing process needs to be smooth and the user mostly is going to draw using a tablet with a Wacom interactive pen display so the experience needs to be good, something like Microsoft OneNote or any drawing app. On Mac and with a high display it works fine but on windows I start encountering some problems, specially when I try to draw something small. It looks like the drag positions are not precise. Any Ideas
I created an algorithm inspired from other projects for making the drawing smooth, also I made some changes for the detectDrag function to make the drag start immediately and those changes make the experience better but still having some issues when I try to draw something small
k
“some problems”, “some issues” - this is very vague. The more specific you are in your description, the higher the chances are for specific, concrete answers
m
I will try to attach a recording, but my main question is if there's some optimizations that I could use to get more precise drag positions optimized for a Wacom pen display
a
It sounds like you’re seeing the slop at work.
If you start by dragging a lot, and then make small drags (without lifting the pen), does it work ok?