Assign one of several inputs to an outlet
Name | Type | Opt | Description |
---|---|---|---|
number-of-inputs and initially-open-inlet | int | opt | The first argument specifies the number of input signals. The default is 1. The second argument specifies which signal inlet is initially open for its input to be passed through to the outlet. The default is 0, where all signals are shut off and a zero signal is sent out. If a signal is connected to the left inlet, the second argument is ignored. |
int | open-inlet [int] |
In left inlet: If a signal is not connected to the left inlet, an | or determines which input signal in the other inlets will be passed through to the outlet. If the value is 0 or negative, all inputs are shut off and a zero signal is sent out. If it is 1 but less than 2, the signal coming in the first inlet to the right of the leftmost inlet is passed to the outlet. If the number is 2 but less than 3, the signal coming into the next inlet to the right is used, and so on.
signal | In left inlet: If a signal is connected to the left inlet, selector~ operates in a mode that uses signal values to determine which of its input signals is to be passed to its outlet. If the signal coming in the left inlet is 0 or negative, the output is shut off and a zero signal is sent out. If it is 1 but less than 2, the signal coming in the first inlet to the right of the leftmost inlet is passed to the outlet. If the signal is 2 but less than 3, the signal coming into the next inlet to the right is used, and so on. In other inlets: Any signal, to be passed through to the selector~ object's outlet depending on the value of the most recently received int or float in the left inlet, or the signal coming into the left inlet. The first signal inlet to the right of the leftmost inlet is considered input 1, the next to the right input 2, and so on. If the signal network connected to one or more of the selector~ signal inlets contains a begin~ object, and a signal is not connected to the left inlet of the selector~, all processing between the begin~ outlet and the selector~ inlet is turned off when the input signal is not being passed to the selector~ outlet. |
Name | Description |
---|---|
begin~ | Define a switchable part of a signal network |
gate~ | Route a signal to one of several outlets |
switch | Output messages from a specific inlet |
MSP Tutorial 5: Turning Signals On and Off | MSP Tutorial 5: Turning Signals On and Off |