POV-Ray : Newsgroups : povray.general : Rotating an object so it is tangent to a spline. : Re: Rotating an object so it is tangent to a spline. Server Time
29 Jul 2024 10:31:01 EDT (-0400)
  Re: Rotating an object so it is tangent to a spline.  
From: D103
Date: 14 Oct 2011 00:10:01
Message: <web.4e97b4fd3f98dc0e5ae2687f0@news.povray.org>
Le_Forgeron <jgr### [at] freefr> wrote:
>
> what about creating the cylinder at the right position & orientation
> first ? (instead of creating it and moving it)
>
> tangent to spline Path1 at P is something like looking at P+epsilon.
>
> #local CurPoint=Path1(P);
> #local Soon=Path1(P+epsilon);
> cylinder { CurPoint+50*vnormalize(Soon-CurPoint),
>            CurPoint+50*vnormalize(CurPoint-Soon), 1
> ...
>
> (assuming you want the center of cylinder on spline)

Thanks very much, I have tried this and I think that with a little tweaking it
will meet all of my requirements for both test scenes, and the animation as
well.

I think I will retain the use of a spline as well, as it will allow me to have
several shells in the air at the same time, especially with a shell flight time
of ~24 seconds.

Many thanks,
D103


Post a reply to this message

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