Add an output pulse so selects can easily be cascaded:
Now we can cascade to provide more inputs:
Add an output pulse so selects can easily be cascaded:
Now we can cascade to provide more inputs:
We have a better idea, I think. I one of the future releases we’ll make it possible to “scale” nodes. In the context of select
node, it would look like following: you drag a resize handle, and as you make the node wider, it gets S3, X3; S4, X4; etc until you’re satisfied with its arity. The same will be available for nodes like add
, concat
and many others.
Will it blend?!
Until that I recommend creating a handy set of select-3
, select-4
,… using multiple select
’s and any
’s
Scaling nodes would be very cool if you can get it to work. It is a pain right now to delete the node & create a new one with more inputs & have to re-connect all the wires.
You might still want to consider adding an output pulse to the select node. It also came in handy for setting buffer from multiple locations and there are probably other uses as well.
Hmmm…thinking about how to do scaling nodes for lcd, it might not be that difficult to implement for C++ nodes. You basically just need a way to create scaling inputs/outputs and a way to reference them in C++ (? getValue<input_L[i]>(ctx) for index i?). C++ code would have to have a key to indicate how many scaling inputs/outputs there are (? getValue<input_L_scale>(ctx) ?) and use a loop to process them. Do you provide a way to specify number of each scaling input/output, or resize the node and have the same number for all scaling input/output? The latter might be easier and there may not be a use-case for the former (though I’m sure someone would find a use if it existed). If you allow independent scaling, you might need a way to say they need to be the same (select is going to have odd behavior if X & S have diff counts).
Of course when I say “not that difficult”, I’m ignoring the behind-the-scenes implementation for GUI & compiler… but my initial thought was trying to figure out how to graphically create a scaling node by expanding syntax currently used by nodes like concat-3, and that was causing brain cramps…