|
|
Can functions be procedural rather than mathematic? If so can someone show
me how it might be done
i.e rather than..
#declare foo2 = function(x, y, z) { x + y * z }
can I do something like this, where the function returns a variables
value....
#declare foo2 = function(x, y, z)
{
#declare r = 0;
#if(x>10)
#declare r = 0.5;
#end
#if(y>10)
#declare r = r + 0.5;
#end
return r
}
--
#include"colors.inc"#include"metals.inc"text{ttf"arial.ttf""Felbrigg"1,0text
ure{pigment{Red*.9}}translate<-1.8,0,0>}sphere{<0,0,0>,6hollow
texture{T_Chrome_5E}}camera{location<0,0,-5>look_at<0,0,0>}light_source{<0,-
2,-5>colour White}
Post a reply to this message
|
|