• Advertisement
Sign in to follow this  

Problem with html5 canvas and drawing app

This topic is 980 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement

You can catch mouse move event over entire document area and translate it into canvas instead. If I understand corectly that your problem is that last mousemove on canvas is not exactly on the egde, leaving your trace unfinished into very next out-of-canvas position. This would also allow you to strat brushing when mouse returns onto canvas from the very outer space, starting on canvas from the last resoluted point out of canvas into first mouse-move point on canvas.

Share this post


Link to post
Share on other sites

Well I already tried that the problem is the canvas is the size of the document so the cursor practically leaves the browser. 

Share this post


Link to post
Share on other sites

Well I can then surely tell, that you then have only a very few choices there.

 

One quite solid one in my opinion would be you could guess the intended trace as a derivative of last three resolved explicit points, and just finsh trace to that gessed derived point onto very edge. It would take a really very fast move to change such a derivative tangentiality more rapidly.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement