Forum: Poser - OFFICIAL


Subject: Bagginsbill or other guru - shader question

JoEtzold opened this issue on Dec 08, 2008 · 35 posts


bagginsbill posted Wed, 10 December 2008 at 4:24 PM

Colors have always been full range numbers in Firefly shaders, since Poser 5 and up. WHITE + WHITE = 2 * WHITE has always been the case.

The preview of such things, of course, cannot show you double white. Nor can it show you negative colors, but they exist and I use them a lot.

Frequently in making color patterns using matmatic I may say something like this:

(3 * a + 100 * b) / 103

If a and be are numbers, this is perfectly reasonable for any numbers even those outside the range 0 to 1.

For colors, we whink this is impossible, because (3 * RED + 100 * BLUE) / 103 seems like nonsense. But of course colors are not colors at all until we try to draw them. Until then, they are just vectors with 3 elements. [r, g, b]

So all the Color_Math nodes in Poser should really be called Vector_Math nodes because that is what they are.

Our displacement maps, when visualized as a gray-scale image, do seem to be limited to 0 to 1. But as soon as you start to combine them using math, they can easily go outside that range and quite often this is completely desirable.

If you wish to limit something to the range 0 to 1, whether a single number or a color (vector) you simply use a Math:Clamp or Color_Math:Clamp node. All values will be limited to 0 to 1.

In matmatic, given you want to limit the sum a + b, you say:

Clamp(a + b)

It does not matter if a and b are numbers or colors - matmatic will use the correct node automatically.


Renderosity forum reply notifications are wonky. If I read a follow-up in a thread, but I don't myself reply, then notifications no longer happen AT ALL on that thread. So if I seem to be ignoring a question, that's why. (Updated September 23, 2019)