Live data from Hacker News

Lazy-brush – smooth drawing with mouse or finger

lazybrush.dulnan.net

51–60 of 83 posts

Re: Lazy-brush – smooth drawing with mouse or finger

#51

I think it would be much better to use some kind of Kalman filtering so you don't have the huge lag. You don't need to commit to permanent output immediately so it is possible to draw with zero lag and then smooth the output afterwards.

Yeah it’s a nice brush model but that is a huge gap between the input and ink.

Re: Lazy-brush – smooth drawing with mouse or finger

#52
post #13

An alternative that works very well for signatures too is Perfect Freehand (by the guy behind TLDRaw) https://perfect-freehand-example.vercel.app/

This is fantastic! Never in my life could I input my signature with a mouse, and have it come out this close to how it looks like the pen-and-paper version. Mindblowing, as it worked like so out of the box.

Re: Lazy-brush – smooth drawing with mouse or finger

#53
post #2

This is so satisfying. These types of experiments are something I really love about the open-web, and part of what bums me out about how most social networks tend to throttle links. The dragging behavior is so intuitive – it's funny because usually if you create this kind of resistance in a UI it can be confusing, but in this context it works so well.

I dunno why people are praising this, because it makes it impossible to do natural scribbles. It's picking the algorithm over the result.

Perfect freehand is the right way to solve this.

Re: Lazy-brush – smooth drawing with mouse or finger

#54
This technique was also used in mid-late non-motion-plus Wii games to smooth out the pointer movement! Early games hadan incredibly twitchy pointer because they were simply mapping the IR data 1:1 to cursor movement, whereas later ones have an invisible circle around the cursor and only move the cursor itself once the circle edges start "dragging" it.

Re: Lazy-brush – smooth drawing with mouse or finger

#55

I think it would be much better to use some kind of Kalman filtering so you don't have the huge lag. You don't need to commit to permanent output immediately so it is possible to draw with zero lag and then smooth the output afterwards.

Kalman filtering is what's used in GPS navigation apps, is it not, to smooth out imperfections in the raw GPS signal?

Re: Lazy-brush – smooth drawing with mouse or finger

#56
post #13

An alternative that works very well for signatures too is Perfect Freehand (by the guy behind TLDRaw) https://perfect-freehand-example.vercel.app/

Using a trackball I couldn't get this to work noticeably better than just plain paintbrush input in MS Paint. Conversely the one from TFA took me a little more time to get the hang of but I got a lot better control with it.

Re: Lazy-brush – smooth drawing with mouse or finger

#60

I think it would be much better to use some kind of Kalman filtering so you don't have the huge lag. You don't need to commit to permanent output immediately so it is possible to draw with zero lag and then smooth the output afterwards.

Kalman filtering is what's used in GPS navigation apps, is it not, to smooth out imperfections in the raw GPS signal?

Yep. You can use it for estimating all sorts of things based on noisy measurements.
Post reply on HN