Try in your trace loop
#if(vdot(y,vnormalize(Norm))>0.9725)
where 0>.9725 is the flatness of the angle of flatness you want.
or
#if (VAngleD(Norm, y) < 20) from math.inc which you need to include
This will place trees only on the flatter parts of your height field.
Thanks to Tor OLav Kristensen
Mick
Post a reply to this message
|