|
 |
On 22/11/2022 13:11, Tor Olav Kristensen wrote:
>
> Hi Kurz
Hello
> I don't know if it was your intention to not extract the filter and
> transmit components of the color.
Yes, in this case, I am not interested in the values of t and f.
I want to use the color_map as a lookup table to draw the julia sets.
> If you write the macro like this:
>
>
> #macro GetColor(ThisColorMap, ThisEntry)
>
> #local Index = max(0.0, min(ThisEntry, 1.0));
> #local Gradient = pigment { gradient x color_map { ThisColorMap } }
> #local GradientFunction = function { pigment { Gradient } };
> #local Color = color GradientFunction(Index, 0, 0);
>
> Color
>
> #end // macro GetColor
>
>
> - then it will extract all the color components.
>
> You'll also get a faster macro because of only one call to the pigment
> function instead of three.
Well seen !
Thanks
--
Kurtz le pirate
Compagnie de la Banquise
Post a reply to this message
|
 |