POV-Ray : Newsgroups : povray.general : Can anyone shorten this sig? : Re: Can anyone shorten this sig? Server Time
5 Aug 2024 22:14:22 EDT (-0400)
  Re: Can anyone shorten this sig?  
From: Tom Melly
Date: 18 Jul 2002 17:37:50
Message: <3d37352e@news.povray.org>
"Ron Parker" <ron### [at] povrayorg> wrote in message
news:slr### [at] fwicom...

> Parse time is slightly worse, because I removed the short-circuit on the
inner
> (V) loop, but the results are the same...
>
> #local T=-2;#while(T<2)#local U=2;#while(U>-2)#macro
M(X,Y,V,W)#while(V<9)#local
> Z=X;#local X=X*X-Y*Y+U;#local Y=2*Z*Y+T;#if(X*X+Y*Y>4)#local
W=0;#end#local V=V+
> 1;#end#if(W)#macro L(S)box{0,.02 pigment{rgb 9}translate<T+S,U+1,6>}#end
L(-2)L(
> 0)L(1)L(2)#end#end M(-U,-T,0,1)#local U=U-.03;#end#local T=T+.05;#end//Tom
Melly
>

Looking at this in detail, the use of a constant passed to a macro puzzled
me, until I realised it saves on #locals. It makes sense if you can save on
2 or more of 'em.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.