POV-Ray : Newsgroups : povray.newusers : Trace and Normal Server Time
5 Nov 2024 01:21:41 EST (-0500)
  Trace and Normal (Message 1 to 2 of 2)  
From: Tim McMurdo
Subject: Trace and Normal
Date: 28 Sep 2002 10:21:54
Message: <3d95bb02$1@news.povray.org>
I am using the trace feature to place an object on top of a wave. I have
figured that part out fairly well.

However, I want to make the object rock back and forth on the wave by
aligning the object with the normal at the point it sits on the wave.

I know tat the trace function will find the normal for me, but I can't
figure out how to use that normal to rotate my object.

Can anybody show me some sample code that will do this for me?

Thanks,

Tim


Post a reply to this message

From: Christoph Hormann
Subject: Re: Trace and Normal
Date: 28 Sep 2002 10:34:21
Message: <3D95BDED.AEEE5BE9@gmx.de>
Tim McMurdo wrote:
> 
> [...]
> 
> I know tat the trace function will find the normal for me, but I can't
> figure out how to use that normal to rotate my object.
> 
> Can anybody show me some sample code that will do this for me?

You should try the 'Reorient_Trans()' macro in 'transforms.inc'.

Christoph

-- 
POV-Ray tutorials, IsoWood include,                 
TransSkin and more: http://www.tu-bs.de/~y0013390/  
Last updated 13 Aug. 2002 _____./\/^>_*_<^\/\.______


Post a reply to this message

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