POV-Ray : Newsgroups : povray.general : I was disappointed with six lines : Re: I was disappointed with six lines Server Time
7 Aug 2024 23:23:22 EDT (-0400)
  Re: I was disappointed with six lines  
From: Wlodzimierz ABX Skiba
Date: 7 May 2001 05:33:38
Message: <3af66bf2@news.povray.org>
Nekar Xenos wrote in message <3af64708@news.povray.org>...
>
> Very clever, i love it.

Thanks

> Nekar
> --
> #version unofficial MegaPov 0.7;#local Q=seed(7);#local S=<-2,2,5>;#local E=<2
> ,-2,5>;#local B=S;#while(vlength(B-E)>.1)#local B=(B+(<rand(Q),rand(Q),rand(Q)
> >/20));#local B=B-(2*(B-S))*((vlength(B-E)>vlength(S-E)));#local S=B;glow{//NX
> location S size.1 radius.07}glow{location S size.1 radius.07 rotate z*90}#end

can I suggest some optimizations ?

#version unofficial MegaPov.7;#local Q=seed(7);#local B=<-2,2,5>;#local E=<2,-
2,5>;#while(vlength(B-E)>.1)#local S=B;#local B=B+<rand(Q),rand(Q),rand(Q)//NX
>/20;#local B=B-2*(B-S)*(vlength(B-E)>vlength(S-E));glow{radius.07location<B.y
,-B.x,B.z>size.1}glow{radius.07size.1location B}#end


and becouse of megapov declaration you can use shortcuts for #local of course

ABX


Post a reply to this message

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