POV-Ray : Newsgroups : povray.newusers : isosurface & df3 file Server Time
4 Nov 2024 23:16:48 EST (-0500)
  isosurface & df3 file (Message 1 to 2 of 2)  
From: nomail
Subject: isosurface & df3 file
Date: 25 Aug 2004 12:25:00
Message: <web.412cbd135d8c8855544129010@news.povray.org>
Hello,

I have problems drawing the 0-isosurface of a function f which I know
discrete values stored in a 3D array. I managed to write some c file that
convert the data (approx 100x100x100) I have into a df3 file. I am using
povray 3.6

Let's say f = (x-0.5)^2 + (y-0.5)^2 + (z-0.5)^2 - 0.1, I tried the following

1/ If I directly use the value of f for 0<x,y,z<1 in the df3 file nothing
appears.

2/ If I store 1 for (x,y,z) such that f<0 and otherwise in the df3 file,
povray draws (as expected) a jagged sphere.

I would like to know why method 1 doesn't work properly. Method 2 is ok but
the surfaces are not smooth enough. I thought using a smoother function
(method 1) would help getting smoother isosurface but it look I got
something wrong.

Clue 1: has it to do with the facts density is supposed to be 0 outside of
the unit cube when using density file?

Below are the sdl lines I wrote for this.

#declare f=function{
  pattern{ density_file df3 myfile.df3  }
}

#declare mysurface=isosurface {
  function { f(x,y,z)}
  contained_by {box {<0,0,0>, <1,1,1>} }
}


Post a reply to this message

From: sko
Subject: Re: isosurface & df3 file
Date: 26 Aug 2004 05:10:00
Message: <web.412da82ad015aef46fd83bf40@news.povray.org>
Sorry for my previous anonymous post I misconfigured my account.

I just wanted to add that I tried to draw the isosurface using different
sign for the function (f, -f) with the same blank result each time.

Sko


Post a reply to this message

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