Display MIDI input devices
This example shows how to retrieve a list of MIDI input devices and display them in a umenu object.
This example shows how to retrieve a list of MIDI input devices and display them in a umenu object.
The way audio Max compiles audio signal networks is, whenever audio is turned on, MSP outlets send out the message ‘signal’. (In other words, that’s how Max knows how MSP objects are connected to each other, and thus knows how to calculate the audio signal network.) The [route signal] object detects the selector ‘signal’ and sends a ‘bang’ out its left outlet in response. The [t signal] object converts that ‘bang’ back into the message ‘signal’.
To slow the flow of OSC messages, store the most recent value for each parameter using the combine object, but only send it out as an OSC message at the desired rate.
To use floating point numbers with the poly object separate the integer portion and the fractional portion. Then recombine them after the poly object, as in the example.
Every number that comes in the left inlet of the match object—whether individually or as part of a list—gets used, in order, for the list-matching comparison. So, if it is looking for the list "1 1" and you send in lists "0 1", "1 1", "1 2", and "1 3" in that order, it’s as if match had received "1 0 1 1 1 2 1 3", and in that message it can find two matches for "1 1": at the 3rd and 4th items, and at the 4th and 5th items.
This example demonstrates how to separate items in a formatted message.
This patch shows four objects that are useful for generating numbers, each with a different behavior. The arguments to these objects determine how many different possible numbers the object will generate, and the range of those numbers. The range can be changed, though, by scaling (multiplying) them and/or by offsetting (adding something to) them.
A computer can make a choice between different alternatives based on assigned statistical “likelihoods”—relative probabilities assigned to each possible alternative.
You can send messages to Max wirelessly from a mobile device such as iPhone, iPod Touch, iPad, or Android-based smart phone or tablet, using the TouchOSC app.
Even though Max is graphical, object-based, and event-driven (responds to user events like mouse clicks, key strokes, MIDI data, etc.), it's still sequential. Every message is sent (or scheduled to be sent) at a specific time, and nothing happens truly simultaneously. Therefore, it's important to be conscious of the precise order in which things occur. Study the example above to be sure you understand the way that Max orders messages.