POV-Ray : Newsgroups : povray.programming : Can someone patch POV so that you can output an isosurface as a wire frame? : Re: Can someone patch POV so that you can output an isosurface as a wire fr= Server Time
6 Oct 2024 21:20:47 EDT (-0400)
  Re: Can someone patch POV so that you can output an isosurface as a wire fr=  
From: Warp
Date: 7 Nov 2002 17:38:14
Message: <3dcaeb56@news.povray.org>
normdoering <nor### [at] yahoocom> wrote:
>>  You talked about isosurfaces. Heightfields have nothing to do with that.

> They do from a user's perspective. Both of them take images, jpegs, gifs,
> etc. and derive a z coordinate from the "brightness" of a pixel point.

  I see nowhere in the isosurface syntax description that it would take
an image as parameter. Also nowhere is mentioned anything about a
z-coordinate being derived from this hypotetical image.

  Yes, you can create a pigment from an image, and then use this pigment
to create a pigment function, and then use this function to create an
isosurface. However, that's a property of a pigment, not an isosurface.
There's nothing in the isosurface itself which would make it directly
related to images.
  (Besides, even when you do this, there's absolutely no reason why do
would have to get a z value from the pigment in question; you can use
the pigment to get any value you want, eg. an x or y value, a radius
or whatever.)

> That's the essence of a mesh. The picture gives you pixels in an orderly
> x,y or u,v set of coordinates and the grayscale values give you a z.

  Now I got lost.
  I don't see how images, isosurfaces or heightfields are in any relation
to "the essence of a mesh".

  A mesh is simply a collection of triangles arranged in any way you want,
without any limitations.
  Of course you can create a mesh using data from an image, but that doesn't
make meshes inherently related to images. You don't need an image in order
to create a mesh, even though it's one way of doing it.

> Now if
> you could turn specially drawn pictures into mesh structures and manipulate
> them like you can manipulate an isosurface you'd have a way of making
> intricate, but very large, wireframe/mesh models.

  You are making things a lot more complicated than they are. Simply forget
all that stuff about isosurfaces. They have nothing to do with what you want
to do. Your question clearly seems to be:

  "How can I create a mesh which is like a heightfield using an image?"

  I gave you the answer previously: See the section 7.13.1.1 of the
POV-Ray 3.5 documentation. You can adapt the implementation of those macros
for your purposes.

-- 
#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

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