|
|
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
stevenvh wrote:
> Hi,
> I'm using a macro which is called only a few (7) times:
>
> /* code starts here *********************************************************/
> #macro DrawShelfSection( aLeft, aRight, aY, aSlanting )
> #declare InvCosSl = 1 / cos ( 180 * aSlanting / pi );
> ...
> #declare xx = Left;
> #while (xx < Right)
> ...
> #if (xx + Bwidth <= Right)
> DrawBook( xx, aY, Bheight, Bwidth, aSlanting, RandomColor > )
> #end
> #declare xx = xx + Bwidth * InvCosSl;
> #end
> #end
> /* code ends here ***********************************************************/
>
> When I start rendering the "tokens parsed" counter starts and runs until POVray
> crashes at about 270 million (!) tokens parsed.
> When I change the last declaration to
>
> #declare xx = xx + Bwidth;
>
> everything runs fine (with only 660000 tokens parsed).
> I first thought the error may have been caused by the 10000x10000 pixel image,
> but it also happens on a 500x500.
> You can find the error msg dialog at http://www.nenya.be/temp/povray_err.png.
>
> Ideaz anyone?
My bet is: at least once in the full code, you call your macro with
a value of aSlanting which causes the cos to be negative, at which
point your macro goes left indefinitely and never reaches the
"Right" position...
Jerome
- --
+------------------------- Jerome M. BERGER ---------------------+
| mailto:jeb### [at] freefr | ICQ: 238062172 |
| http://jeberger.free.fr/ | Jabber: jeb### [at] jabberfr |
+---------------------------------+------------------------------+
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
iD8DBQFHUxRzd0kWM4JG3k8RAjDGAKCOd7tkafVSB4upitJPSSHdjaKJ9wCglC2b
YQSeFNApkRcWu3VJZfnONK4=
=t9LF
-----END PGP SIGNATURE-----
Post a reply to this message
|
|