mousestate
Description
Provides button status and cursor position information about the mouse/cursor when the cursor is positioned within a Max patcher window. The mouse button is sampled every 50ms, while the mouse position is sampled every input bang.
Examples

Arguments
None.
Attributes
Common Box Attributes
Messages
bang
mode
Arguments
nopoll
poll
reset
zero
Output
int
mousestate must have received at least one or message in its inlet before any output is sent out.
Out left outlet: Each time the mouse button is pressed, is sent out. Each time the mouse button is released, is sent out.
Out 2nd outlet: The horizontal location of the mouse, measured in terms of the number of pixels the mouse is to the right of the 0 point.
Out 3rd outlet: The vertical location of the mouse, measured in terms of the number of pixels the mouse is below the 0 point.
Out 4th outlet: The change in horizontal location of the mouse, since the last time the mouse location was reported.
Out right outlet: The change in vertical location of the mouse, since the last time the mouse location was reported.
See Also
Name | Description |
---|---|
modifiers | |
mousefilter | |
Max Basic Tutorial 8: Keyboard and Mouse Input | Max Basic Tutorial 8: Keyboard and Mouse Input |