> This won't work. What you're actually describing is a method to find how
> many surfaces in the line through a given pixel are, not the depth value.
You are right. I misunderstood the question.
> texture{
> pigment{spherical color_map{[0 rgb ][1 rgb 1]} scale Max_Distance translate
> Camera_Location}
> finish{ambient 1 diffuse 0}
> }
This assumes perspective projection. For orthogonal projection the gradient
pattern might be more suitable than the spherical pattern. That would be:
pigment {
gradient Camera_Direction*Max_Distance
colour_map {[0 rgb 0] [1 rgb 1]}}
translate Camera_Location
}
(assuming a normalized Camera_Direction) and the rest as you said.
--
merge{#local i=-11;#while(i<11)#local
i=i+.1;sphere{<i*(i*i*(.05-i*i*(4e-7*i*i+3e-4))-3)10*sin(i)30>.5}#end
pigment{rgbt 1}interior{media{emission x}}hollow}// Mark Weyer
Post a reply to this message
|