POV-Ray : Newsgroups : povray.advanced-users : Isosurface question : Re: Isosurface question Server Time
28 Jul 2024 18:18:14 EDT (-0400)
  Re: Isosurface question  
From: Andrew C on Mozilla
Date: 21 Jul 2004 17:01:12
Message: <40fed998$1@news.povray.org>
>> #declare Fn1 =
>> {
>>   ( (sin(x) * cos(y) * tan(z))*sqrt(x*y / z) - exp(log(x)*y - z) ) * 
>> (tan(sin(x) * cos(y) * tan(z) + sqrt(x*y / z)) - log(exp(log(x)*y - z)) )
>> }
>>
>> Notice how A, B and C have to be calculated *TWICE*...
>>
>> Is there any way round this??
> 
> 
> Yes. I once presented a solution to this.
> 
> It's halfway down in this message:
> 
> http://tinyurl.com/3f642
>
http://news.povray.org/povray.text.scene-files/message/%3C3fbe6e34%40news.povray.org%3E/#%3C3fbe6e34%40news.povray.org%3E


Aaaahhhh.... I seeeee..... If a pass a variable into a second function, 
POV-Ray calculates the value to pass ONCE, and then passes it, and it 
can then be used multiple times within the second function... excellent!

The *real* function I want to render is recursive... POV-Ray reports 
412K tokens. (!!) If I can figure out how to do it this way, it will 
hopefully parse raster and render lots faster too... (Will probably have 
to use the file-I/O directives to write an SDL file, then #include it 
back in.)

Thanks for that!

Andrew @ home.


Post a reply to this message

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