|
|
Tor,
Have you tried 'average'? I have used this to achieve similar control as your
technique (though not so complicated). Here is how I do it...
#declare F_Red = function{(sin(x)+sin(y)+sin(z)+3)/6}
// Or any function between 0 and 1
#declare F_Green =function{(cos(x)+cos(y)+cos(z)+3)/6}
#declare F_Blue =function{(sin(-x)+sin(-y)+sin(-z)+3)/6}
#declare P_Red =
pigment
{
function{F_Red(x,y,z)}
colour_map
{
[0 rgb <0,0,0>][1 rgb <3,0,0>]
// Note the colour max is 3, not 1
}
}
#declare P_Green =
pigment
{
function{F_Green(x,y,z)}
colour_map
{
[0 rgb <0,0,0>][1 rgb <0,3,0>]
}
}
#declare P_Blue =
pigment
{
function{F_Blue(x,y,z)}
colour_map
{
[0 rgb <0,0,0>][1 rgb <0,0,3>]
}
}
#declare P_Average =
pigment
{
average
pigment_map
{
[1 P_Red]
[1 P_Green]
[1 P_Blue]
}
}
Then you have a pigment with control over rgb channels without semi transperent
layers.
Post a reply to this message
|
|