2

Here's the Wave Texture Node:

Wave Texture (Color) (Fac)

It's got two outputs: "Color" and "Fac"

The documentation defines them as "Texture color output," and Factor is defined as "Texture intensity output."

Experimentally, these always seem to be produce the same thing, as far as I can tell. What's the difference betw?

1 Answers1

4

It's the same as on other texture nodes, a Color output gives a 3-dimensional vector as output value, while the Fac gives a 1-dimensional floating point value as output. Which means Color gives you RGB values (which can be taken or interpreted as XYZ values where needed), whereas Fac gives a greyscale value between 0 and 1.

In case of the Wave Texture node this does not seem obvious, because when you choose an axis e.g. X, it takes the X values and outputs them on R, G and B channel which only results in greyscale values as well. I guess it is mostly to keep the texture nodes consistent to have both, a Color and a Fac output.

One thing might be that if some nodes only accept single values as input you would have to take the Color and a Separate RGB/XYZ node to pick one of those values. Or if a node only accepts vectors and you have a Fac output, you would need a Combine RGB/XYZ node and plug the greyscale value into all sockets to create a vector.

Now in almost all cases Blender is doing this automatically. Plug a greyscale value into a vector socket: automatically the value will be set on all three channels RGB or XYZ. Plug a color into a single float socket: Blender calculates a grey value from these three channels and sets it as value for the input.

However in some cases like the Noise Texture it is not the same. A default color ramp with black and white on left and right end converts colors into grey values, but the output of the Fac value and Color converted to greyscale do not give the same result.

This has something to do with chromatics, how color intensity and saturation are perceived and how they are displayed with Gamma correction and other things which are now too much explain and I'm not really an expert for this. Just keep in mind, a Color output gives a vector result and a Fac output gives a float value. A Gradient Texture is the same, you only get greyscale colors from both outputs, but still a Color output is a vector.

Gordon Brinkmann
  • 28,589
  • 1
  • 19
  • 49
  • I think the implicit conversion from color->float is based on L in a HCL color model, whereas I believe the noise Fac is the V of a HSV color model. The former weighs green more heavily and blue less heavily (perceptually, we describe 010 as brighter than 001.) Implicit conversion of vector->float is the average of the three components (which I think is the same as V in HSV.) Blender's variable typecasting is really weird and confusing and black magicky. – Nathan Jan 10 '23 at 15:52
  • @Nathan No, it's not black magicky and there's enough resources for colorspaces and methods for color conversion, sRGB displays etc. on the web - but I don't think it's necessary to study those things just for answering the question why there are Color and Fac outputs on the node although they both output greyscale colors. – Gordon Brinkmann Jan 10 '23 at 21:53
  • Sorry, I didn't realize you were just skipping over details for anticipated question interest. Makes sense! – Nathan Jan 10 '23 at 22:57