Forums > MaxMSP

Mouse X and Y position

Jun 17 2012 | 12:47 am

Hello everybody,
Can somebody help me with a doubt? So, I have a jit.window, how can I define X and Y coordinates for the mouse, so it can load a picture or movie when the mouse achieves X and Y values?

Jun 17 2012 | 2:15 am

the lcd object could help you, you can have it invisible over your jit.window and it will detect mouse clicks and mouse position. I hope this can get you started.

Jun 17 2012 | 2:36 am

Are there any example patches so I can take a look?

Jun 17 2012 | 3:22 am

I disagree with jbl. (I’m not sure how one would even do what he proposes, unless he’s referring to jit.pwindow rather than jit.window.) But jit.window (and jit.pwindow) already will send a ‘mouse’ message out the right outlet in response to mouse dragging in the window. Try dragging in the ‘MouseOnMe’ window in this example.

-- Pasted Max Patch, click to expand. --

Jun 17 2012 | 10:22 am

Jbl is very confusing to me… I tried with your example but I think I am missing someting…
I am sorry, I am very new on Jitter.

  1. routemouse.maxpat
Jun 17 2012 | 4:07 pm

Your example suggests that you would benefit from studying the Jitter tutorials and the Max tutorials if you have not already done so. (Your patch contains some basic conceptual errors.) Meanwhile, here is an example that does what I imagine you might be trying to make happen; it plays the movie whenever the mouse is clicked in the lower right quadrant of the window.

-- Pasted Max Patch, click to expand. --

Jun 18 2012 | 6:25 am

Hahaha I am so sorry! Christopher Dobrian is right.

Jun 19 2012 | 1:30 am

Thank you for the Patch!

Viewing 8 posts - 1 through 8 (of 8 total)

Forums > MaxMSP