|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Wasn't it Tom Melly who wrote:
>It occured to me that getting an iso-surface function to output a mesh-file
>rather than generating a scene could be a fairly trivial patch. Is this correct?
>What am I missing?
Such a facility is available for parametric isosurfaces.
Is it possible to convert an arbitrary isosurface function into
parametric co-orinates?
--
Mike Williams
Gentleman of Leisure
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Such a facility is available for parametric isosurfaces.
>
> Is it possible to convert an arbitrary isosurface function into
> parametric co-orinates?
I've been there. There is no trivial method for achieving this. It gets ugly
just as soon as you leave the trigonometric domain.
Ruy
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Wasn't it Ruy who wrote:
>> Such a facility is available for parametric isosurfaces.
>>
>> Is it possible to convert an arbitrary isosurface function into
>> parametric co-orinates?
>
>I've been there. There is no trivial method for achieving this. It gets ugly
>just as soon as you leave the trigonometric domain.
I think it might be possible for functions that can be solved for one of
the variables. I.e. if you can convert from
F(x,y,z) = 0
to
z = G(x,y)
Then you should be able to express the function as the parametrics
x = u
y = v
z = G(u,v)
For example, the sphere given by
#declare F = function {x*x + y*y + z*z - 1}
can be converted into the two sets of parametrics
#declare Fx=function(U,V){U}
#declare Fy=function(U,V){V}
#declare Fz=function(U,V){sqrt(1-U*U-V*V)}
and
#declare Fx=function(U,V){U}
#declare Fy=function(U,V){V}
#declare Fz=function(U,V){-sqrt(1-U*U-V*V)}
(One using the +ve sqrt and one the -ve)
Parts of this can be converted into a mesh using Ingo's include file.
Unfortunately it freaks out when asked to interpret regions of <U,V>
where the surface doesn't exist.
#include "functions.inc"
camera { location <1, 1, -2> look_at <0, 0, 0>}
sky_sphere { pigment {
function{abs(y)}
color_map { [0.0 color blue 0.6] [1.0 color rgb 1] }
}
}
light_source {<-100,200,-100> colour rgb 1}
// a sphere
#declare F = function {x*x + y*y + z*z - 1}
//converted to a parametric
#declare Fx=function(U,V){U}
#declare Fy=function(U,V){V}
#declare Fz=function(U,V){sqrt(1-U*U-V*V)}
#declare Umin=-0.7;
#declare Umax=0.7;
#declare Vmin=-0.7;
#declare Vmax=0.7;
#declare Iter_U = 20;
#declare Iter_V = 20;
//Converted to a mesh
#include "param.inc"
Parametric()
object {Surface
pigment {rgb 0.9}
finish {phong 0.5 phong_size 10}
no_shadow
}
//The other side
#declare Fz=function(U,V){-sqrt(1-U*U-V*V)}
Parametric()
object {Surface
pigment {rgb 0.9}
finish {phong 0.5 phong_size 10}
no_shadow
}
--
Mike Williams
Gentleman of Leisure
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Mike Williams <mik### [at] nospamplease> wrote:
: if you can convert from
: F(x,y,z) = 0
: to
: z = G(x,y)
... then it's just a heightfield which is pretty easy to create. You
can even use the function image feature for creating an actual height_field
object (which should render even faster than a mesh).
--
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Just as a thought, I think tha'ts true, but not all isosurface's are
representable with heightfields .. many of them are concave.
I think that gets back to 'tesselation isn't trivial'.
However, for many ISO's, I think this would be a good idea; it could reduce
rendering time.
== John ==
"Warp" <war### [at] tagpovrayorg> wrote in message
news:3c2b75cd@news.povray.org...
> Mike Williams <mik### [at] nospamplease> wrote:
> : if you can convert from
>
> : F(x,y,z) = 0
> : to
> : z = G(x,y)
>
> ... then it's just a heightfield which is pretty easy to create. You
> can even use the function image feature for creating an actual
height_field
> object (which should render even faster than a mesh).
>
> --
> #macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb
x]
> [1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
> -1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// -
Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
John D. Gwinner <jgw### [at] dazsicom> wrote:
: Just as a thought, I think tha'ts true, but not all isosurface's are
: representable with heightfields .. many of them are concave.
All functions that can be reduced to z = G(x,y) are. Those that can't
be reduced to that, arent'. Simple :)
--
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|