POV-Ray : Newsgroups : povray.advanced-users : contour mapping Server Time
30 Jul 2024 00:20:29 EDT (-0400)
  contour mapping (Message 4 to 13 of 13)  
<<< Previous 3 Messages Goto Initial 10 Messages
From: Warp
Subject: Re: contour mapping
Date: 5 Dec 2000 10:04:52
Message: <3a2d0414@news.povray.org>
Wouldn't a pigment (gradient y?) be enough?

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Warp
Subject: Re: contour mapping
Date: 5 Dec 2000 10:20:10
Message: <3a2d07aa@news.povray.org>
Is this what you call a contour map?

http://www.cs.tut.fi/~warp/contour.jpg

  I made the image with this code:

#version Unofficial MegaPov 0.6;

camera { location <-2,15,-10> look_at 0 angle 35 }
light_source { <50,200,-100>, 1 }

isosurface
{ function { y-noise3d(x,y,z) }
  contained_by { box { <-5,0,-5><5,1,5> } }
  scale <1,4,1>
  pigment
  { gradient y color_map
    { [0 rgb 0][.1 rgb 0]
      [.1 rgb <1,.7,.2>][1 rgb <1,.7,.2>]
    }
    scale <1,.25,1>
  }
  finish { specular .25 }
}


-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Paul Jones
Subject: Re: contour mapping
Date: 5 Dec 2000 11:32:43
Message: <3A2D17A0.8989156E@psu.edu>
Sorry.... 

What I want is this: To take a height field, which may or may not be
visible, and to create a series of closed loops, each loop sitting on a
specific elevation and encompasing only one "hill" of the hf. Now,
imagine that I apply a gradient y pigment to the hf, it would be
possible to get this effect, except that I want each "countour line" to
be 3-dimensional, like a pipe. 

One could also envision taking a hf and repeatedly intersecting it with
two plane, so you are left with some thin sliced in the shape of a loop.
I want those loops to be pipes. 

I hope this helps.

paul

Christoph Hormann wrote:
> 
> Paul Jones wrote:
> >
> > Anybody have any ideas on how I could make a contour map of a height
> > field?  I tried trace() and dropping a sphere at a point if it had a
> > specific Y value, drop enough spheres and test for different heights and
> > you statrt to get something which is OK, but it take half-past forever.
> > Any other ideas? maybe a sphere sweep of some kind ??
> >
> > -paul
> >
> 
> I'm not totally sure what you want to do, but as i understand it, you want
> that contour lines only in povray.
> 
> How about just using a partly transparent gradient y texture on the HF.
> 
> If that's not a good solution, it would help a lot if you would say what
> you want to use these lines for.
> 
> Christoph
> 
> --
> Christoph Hormann <chr### [at] gmxde>
> IsoWood include, radiosity tutorial, TransSkin and other
> things on: http://www.schunter.etc.tu-bs.de/~chris/

-- 



--------------------------------------------------}
Paul Daniel Jones
The Pennslyvania State University

pdj### [at] psuedu
http://research.chem.psu.edu/glassgrp/paul

       C            The way is near, but men
     // \           seek it afar. It is in the
    N    N          easy things, but men seek it
    |    ||         in the difficult things.
    C    C          -Menicius
     \\  /
       C
--------------------------------------------------}


Post a reply to this message

From: Paul Jones
Subject: Re: contour mapping
Date: 5 Dec 2000 11:34:54
Message: <3A2D1824.BCC93109@psu.edu>
Warp, that is very close to what I want, but I need (well, _need_ is
subjective :-) the contours to be 3-dimensional, like tubes or sphere
sweeps. In my final image, the actual height-field will not be visible.

-paul

p.s. I like the image :-)

Warp wrote:
> 
>   Is this what you call a contour map?
> 
> http://www.cs.tut.fi/~warp/contour.jpg
> 
>   I made the image with this code:
> 
> #version Unofficial MegaPov 0.6;
> 
> camera { location <-2,15,-10> look_at 0 angle 35 }
> light_source { <50,200,-100>, 1 }
> 
> isosurface
> { function { y-noise3d(x,y,z) }
>   contained_by { box { <-5,0,-5><5,1,5> } }
>   scale <1,4,1>
>   pigment
>   { gradient y color_map
>     { [0 rgb 0][.1 rgb 0]
>       [.1 rgb <1,.7,.2>][1 rgb <1,.7,.2>]
>     }
>     scale <1,.25,1>
>   }
>   finish { specular .25 }
> }
> 
> --
> main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
> ):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/

-- 



--------------------------------------------------}
Paul Daniel Jones
The Pennslyvania State University

pdj### [at] psuedu
http://research.chem.psu.edu/glassgrp/paul

       C            The way is near, but men
     // \           seek it afar. It is in the
    N    N          easy things, but men seek it
    |    ||         in the difficult things.
    C    C          -Menicius
     \\  /
       C
--------------------------------------------------}


Post a reply to this message

From: ingo
Subject: Re: contour mapping
Date: 5 Dec 2000 11:51:17
Message: <Xns9001B57DAseed7@povray.org>
Paul Jones wrote:

>imagine that I apply a gradient y pigment to the hf, it would be
>possible to get this effect, except that I want each "countour line" to
>be 3-dimensional, like a pipe.

Try using "trace" in combination with "evaluate pigment/pattern" to put 
lots of spheres on your HF.

Ingo

-- 
Photography: http://members.home.nl/ingoogni/
Pov-Ray    : http://members.home.nl/seed7/


Post a reply to this message

From: Wlodzimierz ABX Skiba
Subject: Re: contour mapping
Date: 5 Dec 2000 11:56:29
Message: <3a2d1e3d$1@news.povray.org>
Paul Jones wrote in message <3A2D1824.BCC93109@psu.edu>...
>Warp wrote:
> >   Is this what you call a contour map?
> > http://www.cs.tut.fi/~warp/contour.jpg
>
> Warp, that is very close to what I want, but I need (well, _need_ is
> subjective :-) the contours to be 3-dimensional, like tubes or sphere
> sweeps. In my final image, the actual height-field will not be
visible.


he show you proper way
just use gradient y with color map [0 black] [0.9 black][0.9 white][1
white]
and find tool in povray/links or in news/binaries which convert
ouputed image to array in pov
(I don't remeber name nor author)
than run loop which puts sphere on pixels (array entries) different than
black
or use even spline for neighbours

ABX


Post a reply to this message

From: Wlodzimierz ABX Skiba
Subject: Re: contour mapping
Date: 5 Dec 2000 12:02:50
Message: <3a2d1fba@news.povray.org>
Wlodzimierz ABX Skiba wrote in message <3a2d1e3d$1@news.povray.org>...
> and find tool in povray/links or in news/binaries which convert
> ouputed image to array in pov
> (I don't remeber name nor author)


but I have net :-)
http://www.coe.uncc.edu/~adwoodfi/tga.html

ABX


Post a reply to this message

From: Christoph Hormann
Subject: Re: contour mapping
Date: 5 Dec 2000 12:34:24
Message: <3A2D271F.DE0ABA2D@gmx.de>
Wlodzimierz ABX Skiba wrote:
> 
> Wlodzimierz ABX Skiba wrote in message <3a2d1e3d$1@news.povray.org>...
> > and find tool in povray/links or in news/binaries which convert
> > ouputed image to array in pov
> > (I don't remeber name nor author)
> 
> but I have net :-)
> http://www.coe.uncc.edu/~adwoodfi/tga.html
> 

I think you don't need a program for that, eval_pigment is sufficient.

Anyway, using enough spheres to make a smooth pipe will take quite a lot
of time and memory.

Christoph

-- 
Christoph Hormann <chr### [at] gmxde>
IsoWood include, radiosity tutorial, TransSkin and other 
things on: http://www.schunter.etc.tu-bs.de/~chris/


Post a reply to this message

From: Christoph Hormann
Subject: Re: contour mapping
Date: 5 Dec 2000 12:43:45
Message: <3A2D2951.9C95E056@gmx.de>
Paul Jones wrote:
> 
> Sorry....
> 
> What I want is this: To take a height field, which may or may not be
> visible, and to create a series of closed loops, each loop sitting on a
> specific elevation and encompasing only one "hill" of the hf. Now,
> imagine that I apply a gradient y pigment to the hf, it would be
> possible to get this effect, except that I want each "countour line" to
> be 3-dimensional, like a pipe.
> 

That makes things clearer...

I think it should be possible with an isosurface:

use the data for an image_pattern instead of the heightfield and use a
color_map similar to the one Warp suggested like:

color_map {
  [0.00 rgb 0]
  [0.59 rgb 0]
  [0.60 rgb 1]
  [0.61 rgb 0]
  [1.00 rgb 0]
}

Of course that's not enough, because the image_pattern is only 2d.  You
have to add a function for the y direction, for a round pipe it has to be
some trigonometric function.

Christoph

-- 
Christoph Hormann <chr### [at] gmxde>
IsoWood include, radiosity tutorial, TransSkin and other 
things on: http://www.schunter.etc.tu-bs.de/~chris/


Post a reply to this message

From: Wlodzimierz ABX Skiba
Subject: Re: contour mapping
Date: 5 Dec 2000 12:55:17
Message: <3a2d2c05@news.povray.org>
Christoph Hormann wrote in message <3A2D271F.DE0ABA2D@gmx.de>...
> Wlodzimierz ABX Skiba wrote:
> > and find tool in povray/links or in news/binaries which convert
> > ouputed image to array in pov
>
> I think you don't need a program for that, eval_pigment is sufficient.

hmm, strange, there is no tool, I think, which make the same thing
but as macro instead of external program with output to include file
hmm, how will be first .... :-)

> Anyway, using enough spheres to make a smooth pipe will take quite a
lot
> of time and memory.

set of spheres connected with cylinders shouldn't be slow
I don't know what quality he is looking for

ABX


Post a reply to this message

<<< Previous 3 Messages Goto Initial 10 Messages

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