matrixctrl object outputs integers, but these cannot be calculated with + object?

Steve Rummage's icon

Im trying to make matrixctrl output 1, 2, 3, 4 - instead of 0, 1, 2, 3.

I swear this was working properly earlier. Hopefully im missing something?

Max Patch
Copy patch and select New From Clipboard in Max.


Source Audio's icon

matrixctrl outputs a list, not single integer.

what do you want to do with it ?

TFL's icon

Maybe OP wanted to use radiogroup instead of matrixctrl?

Source Audio's icon

or live-tab ?

or ...

Steve Rummage's icon

Thanks guys. I need a set of four toggles that override each other and have independent states of on and off. So basically exactly what matrixctrl does.

But from these, I need outputted integers 1, 2, 3 & 4 for the corresponding toggles. The integers are necessary for calculations in the greater patch.

- I tried using unpack after matrixctrl but it also doesnt seem to output integers?

Thanks TFL, radiogroup would be perfect except it doesnt have a state where all toggles can be off.

Afaik, live.tab doesnt have an option where the buttons behave like toggles, but also allows none to be activated.

Source Audio's icon

this is a better way to get states of each cell.

You can also use radiogroup or live tab with off 1 2 3 4 ...

It really depends on what you want to control with this.

Roman Thilenius's icon

[vexpr $1+1 @scalamode 1]
[unpack 0 0 0 0]

Source Audio's icon

I am not sure what should vexpr help here ?

maybe in some different context ?

I would try one of this :


or

Roman Thilenius's icon

there is a chance that i misunderstood the original question. :)

so he needs a radiogroup with custom look? before i´d use matrixcontrol a custom patch which works with any 2-state control is quickly made: any new click sets all cells to zero except itself, then outputs the cell´s number.

cant find my old forum post, so here we go again...