POV-Ray : Newsgroups : povray.general : Problems performing trace() on object : Re: Problems performing trace() on object Server Time
2 Aug 2024 08:11:51 EDT (-0400)
  Re: Problems performing trace() on object  
From: Tim Nikias
Date: 11 Dec 2004 20:32:21
Message: <41bb9fa5$1@news.povray.org>
First: Where's your heightfield placed? Centered on the origin? Because,
without scalement or translation, it ranges from <0,0,0> to <1,1,1>.
Second: The script only covers the area from <-300,250,0> to <0,0,0>, not
more. If you want it to spread from <-300,250,0> to <300,0,0>, you should
modify this line:
#declare Start = x*(-300*rand(rd)) + z*(250*rand(rd));
to this:
#declare Start = x*(-300*(rand(rd)*2-1)) + z*(250*rand(rd));

That aside, random placement of course has some issues. Even distribution
with a little random noise might work better. But that's just my 2 cents.

Regards,
Tim

-- 
"Tim Nikias v2.0"
Homepage: <http://www.nolights.de>


Post a reply to this message

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