Re: Keyframe access
Re: Keyframe access
- Subject: Re: Keyframe access
- From: Pierre Jasmin <email@hidden>
- Date: Fri, 24 Apr 2009 13:26:17 -0700
- Organization: RE:Vision Effects
get BeforeOrEqual KF value
get AfterOrEqual KF value
get NumKeys and allow index first to last
remove KF at time
clear KF stream (can be just a loop done by us)
set KF Value at time
copy KF (can also be getValueAtTime and setValueAtTime)
if Curve Type (eg step/constant, linear, bezier...) - set Curve Type
assuming a KeyFrame Editor Graph:
- Add Group, and Add Param only in Timeline view
Peter Litwinowicz wrote:
Darrin,
Well first can we make menu choices in FCP and Motion be animatable in the
UI? I've only been asking for 9 years now :-). That's much more important
to me than getting/setting keyframe values (which we would like too). This
would also necessitate a "step" interpolation type (in addition to linear
and bezier) so that menus evaluate to the last keyed value. Just like AE.
It seems something like this would be useful (pseudo-code in c-style because
I still don't "get" Objective C):
GetNumKeyFrames();
GetKeyFrameValue(int whichkeyframe, KeyFrameValue &key);
SetKeyFrameValue(int whichkeyframe, KeyFrameValue &key);
Where KeyFrameValue would have a float of the time of the keyframe, and a
union of all the settable types. Something like:
struct KeyFrameValue {
float keytime;
union {
float floatval;
int intval;
string stringval;
Point pointval;
} val;
}
SetKeyFrameValue would set or replace a key at a given time.
Note it would also be useful to have:
IsKeyAtTime(float time);
There also needs to be a way to set/get the interpolation type for the
animated param. Per-key interpolation type would be the best, for
expandability in the future when that becomes available in the apps. So a
"interpolation type" could be added to the KeyFrameValue struct.
I'm sure there's much more to discuss, but this is a good place to get
started.
Pete
It was great to see several of you at NAB this week! I hope you all
had a great time and made a lot of money. :)
In talking with 3rd party developers about the future of the FxPlug
API, one thing that came up repeatedly was the need for an API that
allows access to the app's keyframe data. I'd like to hear from you
what you want out of such an API. I'm looking at After Effects'
AEGP_KeyframeSuite as a reference, and I'm wondering if it provides
you with what you need, or if you feel anything is missing from it, or
if you find it too cumbersome? (For example, there's an
AEGP_InsertKeyframe () function which appears to tell the app there's
a new keyframe, but doesn't actually set the keyframe's value. Then
there's also the AEGP_StartAddKeyframes () function which appears to
tell the app that there will be new keyframes, but again doesn't
actually allow you to set their values. Seems a little convoluted.)
Anyway, please share your ideas here on the list or with me privately.
And I should say that this in no way guarantees that such a thing will
make it into any future version of any particular application. I'm
hoping we'll be able to implement it, but first we have to design it
and discuss it. :)
Thanks!
Darrin
--
Darrin Cardani
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden