POV-Ray : Newsgroups : povray.beta-test : proposal: evaluate in isosurface : Re: proposal: evaluate in isosurface Server Time
30 Jul 2024 08:26:14 EDT (-0400)
  Re: proposal: evaluate in isosurface  
From: R  Suzuki
Date: 10 Dec 2001 10:02:42
Message: <3c14ce92@news.povray.org>
"Thorsten Froehlich" wrote 
>It causes a lot of people to report holes and 
>other bugs in isosurfaces because they simply forget
>about or (worse) don't understand max_gradient.  
>Only a warning gets their attention.

Yes, they need a warning.  
Thus, the default setting of my proposal is "evaluate on", 
i.e. users will get a warning in default.  

But for advanced users or people who just want to use POV 
scene files written by advanced users, the "evaluate off" 
option should be required.

The below code is an example. There are 20,000 isosurfaces.
It is easy to parse and the rendering speed is quite fast.
Please try it. 
Using this technique, we can generate many interesting objects.
But the current behavior is quite inconvenient for these objects.

R. Suzuki

----------------------------------------------
#include "functions.inc"

camera {location <20,40,28> direction 2.5*z look_at <0,0,0>}

light_source {<-140,200,300> rgb <1.0, 1.0, 0.95>*1.5}
light_source {<140,200,-300> rgb <0.9, 0.9, 1.00>*0.5 shadowless}

#declare r1 = seed(0);

#declare Tex_B =
texture {
   pigment {color rgb <0.90, 0.70, 0.45>}
   normal {dents 1.2 scale 0.01}
   finish {phong 0.2 brilliance 0.25}
}

#declare Fun_Sphere = function {x*x - y*x +z*z}
#declare Crumb =
isosurface {
   function {Fun_Sphere(x,y,z) + f_noise3d(x*2,y*2,z*2)*1}
   threshold 1
   max_gradient 3
   accuracy 0.01
   contained_by {box {-1,1}}
   scale 0.5
}

#declare r1 = seed(0);

#declare I = 0;
#while (I < 1)
   object {
      Crumb
      rotate rand(r1)*360
      scale 0.2+rand(r1)*0.3       
      #declare xx=(rand(r1)-0.5)*20;
      translate <xx,cos(xx),(rand(r1)-0.5)*20>
      texture {Tex_B}
   }
   object {
      Crumb
      rotate rand(r1)*360
      scale 0.1+rand(r1)*0.15
      #declare zz=(rand(r1)-0.5)*20;
      translate <(rand(r1)-0.5)*20,cos(zz),zz>
      texture {Tex_B}
   }
   #declare I = I+0.0001;
#end


Post a reply to this message

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