7
$\begingroup$

Is there some way to select one output from a number of inputs with a Fac, like a Mix shader, but instead of a 0-1 slider, use an integer index (for more than two inputs)?

Example (in Quartz Composer):

Quartz Composer multiplexer

If possible, I would like to use an arbitrary number of inputs (e.g. with Python somehow), but I don't know if that is possible.

$\endgroup$
4
  • $\begingroup$ No, I don't think there is any way to do as you describe, at least not directly. Maybe using some python scripting or PyNodes. $\endgroup$ Sep 5, 2017 at 1:50
  • $\begingroup$ @seaturtle You should add this as an answer rather than an edit to the question - it's a good solution and will be useful to others. You will then be able to mark it as 'accepted'. There is no way currently to do this with an arbitrary number of inputs - I think you've hit upon the optimal solution. $\endgroup$ Sep 5, 2017 at 16:21
  • $\begingroup$ Thanks, @FarewellStackExchange! And @Duarte, that's what I was wondering (I wasn't asking specifically about node groups). $\endgroup$
    – SilverWolf
    Sep 5, 2017 at 17:02
  • $\begingroup$ Thanks for the info, @RichSedman. I was afraid of that—but maybe someone will come by and invent something brilliant. (: $\endgroup$
    – SilverWolf
    Sep 5, 2017 at 17:08

1 Answer 1

6
$\begingroup$

I found a way to do this that takes a fixed number of inputs (it also has the useful property of mixing its inputs given a non-integer):

multiplexer-node-group

This is extensible, but only by manually editing the node group.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .