|
![](/i/fill.gif) |
In article <3aacfffc$1@news.povray.org>, "Tom Melly"
<tom### [at] tomandlu co uk> wrote:
> I want a band of mountains on the horizon that drop to foothills and
> finally a plane as z approaches 0.
>
> #declare MountFunc = function {"ridgedMF" <1,5,3,1/3,50>}
> with
> function{ y + (MountFunc(x*z,0,z)*5)} // (note the x*z)
Try: function {y - MountFunc(x,0,z)*5*min(0, z)}
You were multiplying the x coordinate by z, translating the function by
an amount dependant on the distance along the x and z axis. The version
I gave scales the values returned by the function by an amount dependant
on the z axis, which is what I think you wanted. Also, you subtract from
y to raise the height of the plane...your "mountains" were sinking below
ground level, not rising above it.
The "min(0, z)" prevents "negative" mountains falling off in the -z
direction.
--
Christopher James Huff
Personal: chr### [at] mac com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag povray org, http://tag.povray.org/
<><
Post a reply to this message
|
![](/i/fill.gif) |