POV-Ray : Newsgroups : povray.general : troubles with isosurface /df3 : Re: troubles with isosurface /df3 Server Time
2 Aug 2024 00:11:45 EDT (-0400)
  Re: troubles with isosurface /df3  
From: ialx
Date: 16 Mar 2005 02:40:01
Message: <web.4237e183d60091b1fb6b79d70@news.povray.org>
"Slime" <fak### [at] emailaddress> wrote:
> Alright, just a hunch, but I believe that density files only write values
> from 0 to 1 (er, 0 to 255, but those are scaled down to 0 to 1). Since
> you're not modifying your density file function from that, all of the area
> "outside" the sphere has a function value of 0. But in an isosurface, where
> the function is zero is the *surface* of the object. So maybe that's what's
> causing your problem.
>
> Try using F(x,y,z)*2 - 1 so that the function goes from -1 to 1, and what
> used to be F = 0.5 is now F = 0: the surface.
>
> (I didn't look too heavily at your code so I'm not sure if that's really
> what's going on or not, but no one's answered so I wanted to at least try to
> help.)
>
>  - Slime
>  [ http://www.slimeland.com/ ]

i tried this but the outcome is exactly the same. i get a sphere (different
size of course) but the whole <0,0,0> <1,1,1> cube is filled with speckles.
well the code to write the df3 file does normalize the data for
x^2+y^2+z^2 and then scales it to the range 0..255. so this should be ok.
the way i read the documentation the isofunction draws the surface given by
F(x,y,z)-threshold=0. i have threshold=0.2 in my case. so i have three
explanations

1) my c-code does not produce a correct df3 file.
2) my pov command file is wrong (but it is almost a copy of the example
given with spiral.df3)
3) my version of povray has a bug (Persistence of Vision(tm) Ray Tracer
Version 3.6.1 (g++ 3.4.1 @ i686-pc-linux-gnu)

well thanks for the help anyway


Post a reply to this message

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