Author Topic: Multi material switch?  (Read 308 times)

Hey guys!

Fairly new to SD, especially exposing parameters, and creating switches. I was checking out the documentation on switches. I noticed there are switch nodes, multi-switch nodes, and a material switch node. I was wondering if there is a way to do a multi-material switch approach? How would you guys go about doing that?

I even tried checking the multi material blend node to see if I could use the same switch blending mode that is available in the blend and material blend nodes, but it's not available because everything depends on the color id map.

How would you guys do a drop down switch for 3 or more materials?

Thanks in advance!

It seems to me the easier way to do this (if you have just 3 or 4 materials) is to use three switches with functions.

Here is how I would set it up:
- Plug in four materials into 2 switches, then each of those switches into a third one.
- Build a new integer input parameter, and set it up to be a dropdown with 4 options, each corresponding to one of the materials

- For each switch, go to the panel, then make a new function
- Each function is a simple if/else, using the material switch input parameter we created earlier

I used the >= at the end, though there are any number of ways you could set up your functions. In the end, we get our working multi-material switch!

Hope this helps!

Hey man! Thanks so much for this! I will try this out!