In p5.js v0.4.17 from October 25, 2015 (the one that solved the issue) they are also behaving weirdly: pmouseX/Y is not equal to mouseX/Y when the mouse stops moving (seems to be the same problem reported here) and line(mouseX, mouseY, pmouseX, pmouseY); produces a dashed line.
It seems to work fine with p5.js v0.4.17 from October 13, 2015.
When using p5.js v0.4.20 from December 11, 2015 pmouseX/Y is always equal to mouseX/Y.
I've tried the p5.js files on this issue:
In p5.js v0.4.17 from October 25, 2015 (the one that solved the issue) they are also behaving weirdly: pmouseX/Y is not equal to mouseX/Y when the mouse stops moving (seems to be the same problem reported here) and
line(mouseX, mouseY, pmouseX, pmouseY);
produces a dashed line.It seems to work fine with p5.js v0.4.17 from October 13, 2015.
Code: