POV-Ray : Newsgroups : povray.newusers : Need help with POV-Ray !! : Re: Need help with POV-Ray !! Server Time
29 Jul 2024 02:28:10 EDT (-0400)
  Re: Need help with POV-Ray !!  
From: Alain
Date: 22 Aug 2007 17:00:55
Message: <46cca407$1@news.povray.org>
k1s3k1 nous apporta ses lumieres en ce 2007/08/22 09:21:
> "M_a_r_c" <jac### [at] wanadoofr> wrote:
>> "k1s3k1" <k1s### [at] gmailcom> a écrit dans le message de news:
>> web.46c9227d4683e647197c09550@news.povray.org...
>>> can anyone teach me how to make plants/shrubs etc.. im having problem
>>> finding it out :(
>>>
>> It's a 2 parts problem.
>> 1st- you have to get shrubs.
>> You can make some with this kind of application
>> http://propro.ru/go/Wshop/povtree/povtree.html
>>
>> 2nd- you have to plant them.
>> There is a POVRay function called trace()
>> http://www.povray.org/documentation/view/3.6.1/229/  (item 2.2.1.4.5)
>>
>> Some times ago, I put online a small tutorial for trace() (in French, sorry,
>> but the code is the same for us all)
>> http://marc.jacquier.free.fr/tuts/trace_while/Trace_tut_page1.htm
>>
>> Marc
> 
> Thanks, but i dont understand at all -_-
> 
> I dont know how to start using trace.. is there a template of the code that
> i can modify or something?
> 
> Because the french tutorial confuses me
> 
> 
> 
Trace:
You need to pick a starting point somewhere above the surface you want to test.
Then, you need a trace direction. In your case, it's -y or traight down.
It gives you this:
#declare Normal = <0,0,0>;
#declare Point = trace(My_Position, -y, Normal);

Where Normal return the prependicular to the traced point, if = 0 it means that 
you missed your terrain.
Point is the coordinates of the point of your terrain directly under My_position.

The next step is to place your tree, or anything you want, on the terrain:
object(Tree translate Point)

-- 
Alain
-------------------------------------------------
The tree of liberty must be refreshed from time to time with the blood of
patriots and tyrants.
Thomas Jefferson


Post a reply to this message

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