|
|
> I'm wondering if simply changing the condition to "i < 0.999999" is sufficient.
> The likelihood of the variable falling outside this range is pretty slim. Also,
> to how many decimal places does POV-Ray calculate? I thought the "system
> specific" option in the "str" function returned values using this amount.
"To how many decimal places does POV-Ray calculate" is the wrong
question to ask. POV-Ray asks your CPU to do floating-point
calculations, that's all. POV-Ray doesn't do numerical calculations in
any different way than the rest of your computer.
Also, floating-point numbers don't even work in terms of "decimal places".
Use this:
#local i = 0;
#local numerator = 1;
#local divisor = 6;
#while(i < divisor)
#local x = i*numerator/divisor;
#debug concat("x = ", str(x, 0, -1),"\n")
#local i = i + 1;
#end
and be done with it.
Post a reply to this message
|
|