This is to copy a copy of the message that I made on the processing forum (where I have no answer yet), I thought that I could try here.
Processing is a very cool way to draw material, especially for web pages. Just like the link http://processing.org
Hey, I'm new to processing, I use it to create a hassle-free website, so I draw quite a bit on canvas.
I have a problem with the position of the mouse, although the coordinates, when drawing, consider the upper left corner as the position 0,0; the actual coordinates of the mouse believe that 0.0 is the upper left corner of the browser window.
So my problem is that the canvas works on a centered webpage when the browser changes size, just like the mouse coordinates inside the canvas.
Is there a way to make the coordinates of the mouse relative to the canvas? So can I resize my browser window, and the top left corner will always be 0.0 for mouse coordinates?
So, that is the problem, I donโt know how many ppl here in stackoverflow are experiencing with this, but I hope someone can help me :)
thanks to the community in advance.
source share