POV-Ray : Newsgroups : povray.general : density question : Re: density question Server Time
4 Aug 2024 18:18:56 EDT (-0400)
  Re: density question  
From: Christopher James Huff
Date: 13 Mar 2003 18:01:35
Message: <cjameshuff-8FFB15.18014613032003@netplex.aussie.org>
In article <web.3e70d6f57629df5ca3d219970@news.povray.org>,
 "Jettero Heller" <pov### [at] voltar-confedorg> wrote:

> It's actually occured to me that I can just put several of my lathes one
> with inside the other at different scales.  Then adjust the media values for
> each to make a gradient media effect.  That's a reasonable work around, but
> I was hoping I could do this with density.

You can do it with density, and it will render quite a bit faster than 
the Matrioshka doll method you describe above. Who said you couldn't?

Off the top of my head, I can think of several ways:
As others suggested, use a function pattern. Hint: you can use splines 
in functions. This is the simplest method. You might want to put the 
spline control points in an array and write code to generate the lathe 
and density spline from that, because there isn't one unified method for 
specifying splines. (you can't use a spline as input for a lathe object)

Do something like your Matrioshka doll method with the object pattern. 
The object pattern is solid, either one entry or the other, but you 
could nest object patterns with different scales to get any number of 
steps. This is more difficult to set up or change, and gives a finite 
number of steps instead of a smooth gradient. I don't recommend this 
method, too much work to set up, too inefficient and limited.

I'm assuming your lathe does not fold back on itself, in other words it 
is like a cylinder with varying radius. If this is not the case, you 
need to work on your definition a bit more, because what you described 
can't be done.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

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