POV-Ray : Newsgroups : povray.general : Request for a spline macro Server Time
30 Jul 2024 16:23:22 EDT (-0400)
  Request for a spline macro (Message 1 to 2 of 2)  
From: gregjohn
Subject: Request for a spline macro
Date: 24 Dec 2008 12:20:00
Message: <web.49526e92c71d22234d207310@news.povray.org>
Hello, I was wondering if anyone would like to work on a macro for me, which I
think would greatly help character animation with povray for everyone.

PROPERTIES:
Inputs:
1) an array of five variable vectors. X,Y,Z,T,C, where X,Y,Z are where the point
is supposed to be at time Tn, and C is a control variable.
2) a specific time value T

Output: a vector of three variables: X,Y,Z

1) For every element in the array Xn,Yn,Zn,Tn,Cn  when F(T=Tn) is requested, it
spits out precisely <Xn,Yn,Zn>
2) When  F(Tj) is requested and Tj is not in the list of Tn's, then, between
Xn-1 and Xn, it spits out an <X,Y,Z> which:
a) if Cn=1, then a smooth arc between Xn-1 and Xn+1,
b) if Cn=0, then there is an "ease in" to the point <Xn,Yn,Zn> with time. such
that there is a high speed at the midpoint between Xn-1 and Xn, but the
velocity approaches zero as it gets to Xn.

I can show a classic case of where my M.I.M.E. Man animation looked quite lame
when I was swinging a fist across an arc. It went via a staight line to the
midpoint, and slowed down to the midpoint.  What I'm hoping for is an easy
control where one can just create an array of five-element vectors, and then
call it with a specific clock value.

I've done pieces of this myself, but haven't been able to get it all together.
Just wondering if such a system would benefit anyone else.


Post a reply to this message

From: Reactor
Subject: Re: Request for a spline macro
Date: 24 Dec 2008 13:35:00
Message: <web.49528097b880f19f933503e30@news.povray.org>
"gregjohn" <pte### [at] yahoocom> wrote:
> Hello, I was wondering if anyone would like to work on a macro for me, which I
> think would greatly help character animation with povray for everyone.
>
> PROPERTIES:
> Inputs:
> 1) an array of five variable vectors. X,Y,Z,T,C, where X,Y,Z are where the point
> is supposed to be at time Tn, and C is a control variable.
> 2) a specific time value T
>
> Output: a vector of three variables: X,Y,Z
>
> 1) For every element in the array Xn,Yn,Zn,Tn,Cn  when F(T=Tn) is requested, it
> spits out precisely <Xn,Yn,Zn>
> 2) When  F(Tj) is requested and Tj is not in the list of Tn's, then, between
> Xn-1 and Xn, it spits out an <X,Y,Z> which:
> a) if Cn=1, then a smooth arc between Xn-1 and Xn+1,
> b) if Cn=0, then there is an "ease in" to the point <Xn,Yn,Zn> with time. such
> that there is a high speed at the midpoint between Xn-1 and Xn, but the
> velocity approaches zero as it gets to Xn.
>
> I can show a classic case of where my M.I.M.E. Man animation looked quite lame
> when I was swinging a fist across an arc. It went via a staight line to the
> midpoint, and slowed down to the midpoint.  What I'm hoping for is an easy
> control where one can just create an array of five-element vectors, and then
> call it with a specific clock value.
>
> I've done pieces of this myself, but haven't been able to get it all together.
> Just wondering if such a system would benefit anyone else.

This really sounds similar to the existing spline functionality.  In what way is
it different?

-Reactor


Post a reply to this message

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