|
![](/i/fill.gif) |
So it seems you can't do logical tests on the values of the parameters in a
function either!
#declare densityfunc = function(px,py,pz) {
#if(px > 0 | py < 0)
atan2(py,px)
#else
pi - atan2(py,px)
#end
}
Parse Error: ... undeclared identifier 'px'
That makes it kind of difficult to use functions like atan2() that can behave
differently in different quadrants. How would you get around this kind of
thing? How can I make the function use one equation in some quadrants and a
different equation in other quadrants?
Post a reply to this message
|
![](/i/fill.gif) |