[script] Creating relative values fcurve

Date : Fri, 27 Apr 2007 17:36:37 -0400
To : XSI(at)Softimage.COM
From : "Bernard Lebel" <3dbernard(at)gmail.com>
Subject : [script] Creating relative values fcurve
Hello,

I'm running into this show-stopper.

I'm trying to re-create the fcurve of a relative value expression.
I create the expression, no problem at all.
Then I get its relative fcurve parameter, no problem.
Then I loop over a one dimensional array of time/value numbers, and
create the keyframes:


oFcurve.beginedit(); iLength = oFcurveKeys.length;

for( i = 0; i < iLength; i=i+2 )																	{
   fTime = oFcurveKeys[i];
   fValue = oFcurveKeys[i+1];
   oFcurve.addkey( fTime, fValue, 0, true );
}

oFcurve.endedit();

(in this example I use a loop, but the SetKeys method gives the same
result I'm about to describe)


Now, I get all the keyframes. In this particular, I have two keyframes. The first one is all right. BUT the second one, for the life of me, refuses to be placed anywhere else than at frame 1.0.

If I then print its frame, it's the frame I specified (25, for
example). But in the animation editor, it's located at 1/1. Also, when
viewing its effect in viewport, I can *see* it's 1/1. Yet printing its
frame says 25.

ARGGGGHHHH


Any idea?


Thanks Bernard --- Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body: unsubscribe xsi


Search the XSI List archives here or use the advanced search form to search across mailing lists. Searching help is available.
This site supposedly brought to you by Benjamin Grosser and the Imaging Technology Group.