POV-Ray : Newsgroups : povray.advanced-users : Whats wrong with this isosurface ? : Re: Whats wrong with this isosurface ? Server Time
29 Jul 2024 06:25:20 EDT (-0400)
  Re: Whats wrong with this isosurface ?  
From: Slime
Date: 22 Oct 2002 19:25:53
Message: <3db5de81$1@news.povray.org>
> isosurface {  function { pow( (pow(x,2) + pow(y,2) + pow(z,2) - 1) ,2)  }
> gives no object.
> please tell me why


Remember that in order to find where an isosurface function equals zero,
POV-Ray must test around the function. This means that it tests in areas
where the function is not equal to zero. Now, the function

pow(x,2) + pow(y,2) + pow(z,2) - 1

Is already a little weird outside the zero range. The function

sqrt(pow(x,2) + pow(y,2) + pow(z,2)) -1

would look the same but would have a gradient of 1 everywhere. The former
function has a gradient that gets bigger farther away from zero.

Now, when you square the former function, to get pow( (pow(x,2) + pow(y,2) +
pow(z,2) - 1) ,2), the gradients get a *lot* bigger *really* fast beyond the
surface of the circle. This is probably confusing POV-Ray.

Therefore, if you really want to use this function for some reason, you'll
have to set the max_gradient significantly larger than 1.

 - Slime
[ http://www.slimeland.com/ ]


Post a reply to this message

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