|
 |
"Thomas de Groot" <tDOTdegroot@interDOTnlANOTHERDOTnet> wrote in message
news:496c6dbf@news.povray.org...
>I don't know if we should discuss problems encountered with the use of
>objects from the Object Collection here.
Yes. Best place for it.
> Let me just put forward my puzzlement. When using the spline macro for a
> circular wall, I find that the diameter value often gives a parse error.
> For instance here, with 3.6*z:
>
> #declare Blockwall_Spline =
> spline {
> cubic_spline
> #local I = -0.25;
> #while (I<=1.25)
> I, vrotate(3.6*z,-y*I*360)
> #local I = I + 0.01;
> #end
> }
>
> The message says: "Attempt to access unitialized array element", and
> refers to line 1185 of blockwall.inc.
>
> A value of 2.9*z for instance works correctly, but again, 5*z or 6*z lead
> to the same error. It seems rather random and I fail to see what goes
> wrong, or what I am doing wrong for that matter...
>
> Any idea?
Well I don't think you're doing anything wrong. It looks like a bug, but I'm
having difficulty reproducing it on my machine. I've tried the values that
fail for you and they work for me, which leads me to believe that there may
be a platform dependant element to this problem. At the moment I suspect
that there may be a rounding error buried somewhere in my code, possibly in
the while loop where I 'measure' the length of the spline. I'll try to track
it down.
Am I correct in assuming that the error appears with no other values set and
that the following 2 scene files both produce the error on your machine?
camera {location <0,3,-10> look_at 0}
light_source {<-10,20,-50>, rgb 1}
#include "blockwall.inc"
#declare Blockwall_Spline = spline {
cubic_spline
#local I = -0.25;
#while (I<=1.25)
I, vrotate(6*z,-y*I*360)
#local I = I + 0.01;
#end
}
Blockwall_FollowSpline("")
camera {location <0,3,-10> look_at 0}
light_source {<-10,20,-50>, rgb 1}
#include "blockwall.inc"
#declare Blockwall_Radius = 6;
Blockwall_Arc(360,"")
(These two should both be functionally identical).
Regards,
Chris B.
Post a reply to this message
|
 |