|
|
Hi all,
How do I combine these three?
I already found a function to combine a color and an image map:
#macro pigment_multiply(p1,p2)
#local PR1 = function {pigment{p1}}
#local PR2 = function {pigment{p2}}
#local PR_FRed = function (x,y,z) {PR1(x,y,z).red*PR2(x,y,z).red}
#local PR_FGrn = function (x,y,z) {PR1(x,y,z).green*PR2(x,y,z).green}
#local PR_FBlu = function (x,y,z) {PR1(x,y,z).blue*PR2(x,y,z).blue}
average pigment_map {
[function{PR_FRed(x,y,z)} color_map{[0 rgb 0][1 rgb <1,0,0>*3]}]
[function{PR_FGrn(x,y,z)} color_map{[0 rgb 0][1 rgb <0,1,0>*3]}]
[function{PR_FBlu(x,y,z)} color_map{[0 rgb 0][1 rgb <0,0,1>*3]}]
}
#end
So I use for example:
texture {pigment {pigment_multiply(pigment {color rgb<0,1,0>}, pigment
{image_map {jpeg "image.jpg"}})}}
I tried to use a rgbf color, but that adds no transparency.
How to proceed?
Thanks, Dick
Post a reply to this message
|
|