POV-Ray : Newsgroups : povray.general : arrow, bullets, frisbies, flying pigs : arrow, bullets, frisbies, flying pigs Server Time
12 Aug 2024 01:32:48 EDT (-0400)
  arrow, bullets, frisbies, flying pigs  
From: Tom Melly
Date: 12 Apr 1999 08:01:02
Message: <3711d26e.0@news.povray.org>
Well, i spent the weekend with this and got nowhere useful.

If, you have an object and you want to move it in the direction that it's
pointing, how do you calculate the new position from the old position?

For example, assume that ObjArrow is an arrow that, with a rotation of 0,
points in the Y direction. To move the arrow, you just increase the Y
translation.

or
#declare n = 0;
#while n < 10
 object {ObjArrow translate <0, n, 0>}
  #declare n = n +1;
#end

However, I want to be able to do this for more complex rotations, and ensure
that my object move in the direction of its "surface normal", so to speak.

I assume that there are lots of cos and sin etc, and it's doing my head in
(although I can just about manage the equations for 2 dimensions).

Can anyone help and/or refer me to a good shrink and/or marriage guidence
counsellor?


Post a reply to this message

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