A newer version of Max is available. Click here to access the latest version of this document.

mousefilter

Pass numbers only when the mouse button is up

Description

Use mousefilter when you want to change something with a slider or other user interface object only after releasing the mouse, instead of continuously. This could be useful when the slider's output initiates a time-consuming process which would otherwise destroy the "feel" of the user interface.

Arguments

None.

Messages

bang If the mouse button is up, the bang is sent out the outlet. Otherwise, the bang is ignored.
int input [int]
If the mouse button is up, the number is sent out the outlet. Otherwise, the number is ignored.
float input [float]
If the mouse button is up, the number is sent out the outlet. Otherwise, the number is ignored.
list input [list]
If the mouse button is up, the list is sent out the outlet. Otherwise, the list is ignored.
anything input [list]
Performs the same as list.

Information for box attributes common to all objects

Output

int: The number received in the inlet is sent out only if the mouse button is up.

Examples

Nothing gets through unless the mouse is up

See Also

Name Description
mousestate Report the status and location of the mouse
Max Basic Tutorial 8: Keyboard and Mouse Input Max Basic Tutorial 8: Keyboard and Mouse Input