Constant Shader node = Constant color?

Started by FlynnAD, June 13, 2017, 09:04:38 PM

Previous topic - Next topic

FlynnAD

Hi all,

If a Constant Shader node (with a custom color like orange) is plugged into a PF, and the PF only has Apply High Color on (like green), so that the Constant Shader's color will pass through, and the PF is then plugged into the Color Function of a Surface Layer node, why does the Constant Shader NOT show up on the Surface Layer? Only green will show up, not any orange.

The Constant Shader DOES show up if you open up a local PF shader preview window, so it's a bit confusing why it does not render as such.

Conversely, if you make a second PF that has orange for High and Low color (e.g. making a solid, constant color PF), and plug that orange PF into the first PF (instead of plugging in the Constant Shader), then into the Surface Layer's Color Function, the orange and green both show up.

Am I incorrect in thinking that the Constant Shader is a constant color? I thought this would be faster to calculate than using a PF.

Thanks,
Matt

Dune

As far as I know, the alpha doesn't do much, and it's indeed a constant color (like the blue node constant color), and I never use it.

Oshyan

The setup you initially describe seems to work fine for me. See attached. What is different in your setup?

- Oshyan

FlynnAD

Ahh, that's it.

The Constant Color node is not the same as the Constant Shader node, and I was using the Constant Shader node.

Thanks Oshyan,
Matt

Oshyan

Is there just a "Constant Shader"? I think they're all named for what kind of output they have (Constant Scalar, Vector, etc.).

- Oshyan

FlynnAD

Quote from: Oshyan on June 15, 2017, 06:10:37 PM
Is there just a "Constant Shader"? I think they're all named for what kind of output they have (Constant Scalar, Vector, etc.).

Fair enough; you didn't know there was a Constant Shader; I didn't know there was a Constant Color node.

Right click/ Create Shader/ Surface Shader/ Constant.

My initial issue makes sense now, that you can't plug a Constant Shader into the PF's low-color and expect it to pass through. You can plug a Constant Shader directly below a Compute Terrain, while you cannot plug a Constant Color node directly beneath a Compute Terrain. Learn something new every day...

Matt

Oshyan

Hmm, yes,, but now that I look at the shader you're talking about (which I don't use much and had just forgotten about :D), it seems odd to me as well that it doesn't pass through since it does put out color info. I'll ask Matt (Terragen Software Architect) about it.

- Oshyan

cyphyr

Interestingly it (the constant colour) does pass through the empty low colour channel if the pf is plugged into the child layer input instead of the colour input...
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

Dune

Yes, it's a weirdy, alpha is not doing very much either, afaik.