Hi,
Currently iif is implemented as a "hard" if/else statement in that if not one thing- the other thing must occur.
Please don't ask me why...but I was trying to construct an image that was a single row of (lets say 10) pixels.
And I wanted to assign them each a value. I might naively (ha ha..this is exactly what I did) do something like:
iif( x()==0, 0.020749760758206493, 0);
iif( x()==1, 0.02083269071095121, 0);
iif( x()==2, 0.020591074008640423, 0);
iif( x()==3, 0.020587894424854085, 0);
iif( x()==4, 0.02125898032182231, 0)
...
But for each pixel- as it runs through each condition- the else part is always executed (in this case the "0'). Changing this to $T doesn't help.
I really need a soft "iif" that only does something if the statement is True...but is silent (does nothing) if false.
Is there a way to do this?
Basically I am hoping for a Case/Switch statement. I can't see there is a means to do it now... perhaps there is a reason?
Thanks in advance for any help. I know it is kinda a weird question.
-adam