This is the opposite of what people usually ask for, where when there is no UV Map for an image texture, an average of the image is applied to the model.

However in this case I am asking if there is a way to use an image to generate a single colour that can then be passed through other nodes.

For example in this Screenshot, the image texture would apply as an image texture to the top half, whereas the same image would produce a single colour, pass through a HSB node to be darkened to produce the bottom colour. Currently I am manually selecting the colour.

Texture + Solid Color

  • $\begingroup$ Is it Cycles you are working with? Blender version 2.79b? $\endgroup$ Apr 16 '19 at 13:38

If you shrink the image to a size smaller than a pixel of the render result it will render as average, so you could just change the mapping of the coordinates:

enter image description here

You can use vector mapping node as well.

That might not be the most efficient way to calculate the average, but it's easy to achieve and it works.

  • $\begingroup$ Is this calculating an average or cropping to a corner? eg will a b&w chessboard image fade to gray? $\endgroup$
    – batFINGER
    Apr 17 '19 at 4:14
  • $\begingroup$ It will eventually fade to grey. imgur.com/PyeKlty In case of black and white it is going to be a linear grey so to human eye it is going to be light grey, grey to us is around 21.4% or 18% depending on who you ask. The problem here is that it relies on sampling so it may need a lot of samples for the noise to clear up. $\endgroup$ Apr 17 '19 at 5:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.