POV-Ray : Newsgroups : povray.newusers : POVRAY Animations - Fligh paths Server Time
14 Nov 2024 00:16:43 EST (-0500)
  POVRAY Animations - Fligh paths (Message 1 to 5 of 5)  
From: Charles & Paula
Subject: POVRAY Animations - Fligh paths
Date: 29 Oct 1999 08:11:00
Message: <38198F4D.7FF6047D@cybercable.fr>
I have objects (generated by a molecule viewer) only in .pov format. I
would like to make flight paths for the camera.
The "animsystem" is not compatible with povray 3.1 (semicolomn
problems),

Has anybody  an idea to simply create an animation ?


Thanks

Charles


Post a reply to this message

From: omniVERSE
Subject: Re: POVRAY Animations - Fligh paths
Date: 29 Oct 1999 11:08:00
Message: <3819b850@news.povray.org>
There are a few things out there to create the camera positions and such for
animating along splines.  Chris Colefax has a Spline Generator include for
example which can make camera paths:
http://www.geocities.com/SiliconValley/Lakes/1434/
Here's an older utility, Anim8:
http://www.mindspring.com/~maw01/skinz/skinz.htm
Possibly only lacks semi-colon compatibility, not sure.

Bob

Charles & Paula <pcd### [at] cybercablefr> wrote in message
news:38198F4D.7FF6047D@cybercable.fr...
> I have objects (generated by a molecule viewer) only in .pov format. I
> would like to make flight paths for the camera.
> The "animsystem" is not compatible with povray 3.1 (semicolomn
> problems),
>
> Has anybody  an idea to simply create an animation ?
>
>
> Thanks
>
> Charles
>
>
>


Post a reply to this message

From: Josh English
Subject: Re: POVRAY Animations - Fligh paths
Date: 29 Oct 1999 12:19:46
Message: <3819C91F.21AE6AB@spiritone.com>
There is a way to use bezier curves, and Chris Colefax has one avaiable
at his site at http://www.geocities.com/SiliconValley/Lakes/1434/. If you
are comfortable with a little math, you can use the following trick to
set up a bezier path:

#declare c0 = some vector; // This is the camera's starting position
#declare c1 = some other vector; // This is the first control point
#declare c2 = some third vector; // This is the second control point
#declare c3 = yet another vecotr; // This is the camera's final position

#declare c = clock;
#declare m = 1 - c;

#local cx = c0.x*pow(m,3) + c1.x*c*pow(m,2) + c2.x*pow(c,2)*m +
c3.x*pow(c,3);
#local cy = c0.y*pow(m,3) + c1.y*c*pow(m,2) + c2.y*pow(c,2)*m +
c3.y*pow(c,3);
#local cz = c0.z*pow(m,3) + c1.z*c*pow(m,2) + c2.z*pow(c,2)*m +
c3.z*pow(c,3);

Note that the camera path will not pass through points c1 and c2 most of
the time, they simply define where the path goes. You will also need to
set up a second path like this for the look_at variable. Then just add
them into the camera statement :

camera { location <cx,cy,cz>
               ... }

I'm working on a Cyclopedia entry for this one as well.

Charles & Paula wrote:

> I have objects (generated by a molecule viewer) only in .pov format. I
> would like to make flight paths for the camera.
> The "animsystem" is not compatible with povray 3.1 (semicolomn
> problems),
>
> Has anybody  an idea to simply create an animation ?
>
> Thanks
>
> Charles

--

Josh English
eng### [at] spiritonecom
icq 1946299
"Stress is when you wake up screaming and realize you haven't fallen
asleep yet."


Post a reply to this message

From: Daniel Pirch
Subject: Re: POVRAY Animations - Fligh paths
Date: 29 Oct 1999 15:39:42
Message: <3819f7fe@news.povray.org>
Josh English <eng### [at] spiritonecom> wrote in message
news:381### [at] spiritonecom...
> #local cx = c0.x*pow(m,3) + c1.x*c*pow(m,2) + c2.x*pow(c,2)*m +
> c3.x*pow(c,3);
> #local cy = c0.y*pow(m,3) + c1.y*c*pow(m,2) + c2.y*pow(c,2)*m +
> c3.y*pow(c,3);
> #local cz = c0.z*pow(m,3) + c1.z*c*pow(m,2) + c2.z*pow(c,2)*m +
> c3.z*pow(c,3);

I didn't try it, but wouldn't it also be possible to use the vectors
directly, like:

#local c = c0*pow(m,3) + c1*3*c*pow(m,2) + c2*3*pow(c,2)*m + c3*pow(c,3)
camera {location c ...}

AFAIK the slope at the beginning of the spline (at c0) is the same as the
slope of a line between the first two vectors (c0 and c1).


--
Daniel Pirch
dpi### [at] gmxnet


Post a reply to this message

From: Josh English
Subject: Re: POVRAY Animations - Fligh paths
Date: 1 Nov 1999 12:55:19
Message: <381DD401.81AFBA5A@spiritone.com>
Actually, you are right, I made a slight modification:

#local test = p0*pow(m,3) + p1*c*3*pow(m,2) + p2*3*pow(c,2)*m + p3*pow(c,3);

will give the correct vectors. I pulled mine out of a calculus textbook and
I didn't think to try to compress it. It was written in only two dimensions,
but it was easily adaptable. You are right about the slopes, the line from
c0 to c1 is tangential to the final drawn curve.

Thanks for pointing this out. Makes my life a bit easier since I'm abusing
this trick a lot recently

Daniel Pirch wrote:

> Josh English <eng### [at] spiritonecom> wrote in message
> news:381### [at] spiritonecom...
> > #local cx = c0.x*pow(m,3) + c1.x*c*pow(m,2) + c2.x*pow(c,2)*m +
> > c3.x*pow(c,3);
> > #local cy = c0.y*pow(m,3) + c1.y*c*pow(m,2) + c2.y*pow(c,2)*m +
> > c3.y*pow(c,3);
> > #local cz = c0.z*pow(m,3) + c1.z*c*pow(m,2) + c2.z*pow(c,2)*m +
> > c3.z*pow(c,3);
>
> I didn't try it, but wouldn't it also be possible to use the vectors
> directly, like:
>
> #local c = c0*pow(m,3) + c1*3*c*pow(m,2) + c2*3*pow(c,2)*m + c3*pow(c,3)
> camera {location c ...}
>
> AFAIK the slope at the beginning of the spline (at c0) is the same as the
> slope of a line between the first two vectors (c0 and c1).
>
> --
> Daniel Pirch
> dpi### [at] gmxnet

--

Josh English
eng### [at] spiritonecom
icq 1946299
"Stress is when you wake up screaming and realize you haven't fallen asleep
yet."


Post a reply to this message

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