Re: Question about memory calls for FxPlugs in both Motion and FCP
Re: Question about memory calls for FxPlugs in both Motion and FCP
- Subject: Re: Question about memory calls for FxPlugs in both Motion and FCP
- From: Darrin Cardani <email@hidden>
- Date: Tue, 19 Jul 2011 11:39:07 -0700
On Jul 19, 2011, at 10:53 AM, Peter Litwinowicz wrote: So I see that there are new memory calls within the FxPlug API. Cool.
Can you guys at Apple comment on (a) whether I NEED to call these calls or it just helps if we do. I'm certainly willing to change our code since all our memory management is done internally if a very small localized area that all mem calls go through. But I'm curious if we need to.
You do not need to call them, but you can if you want to. (b) if Motion sees that memory is running low when I request memory, does it try to release some internal caches and free up memory before failing and returning NULL? I guess my question is this: do the FxPlug alloc/free calls do more than just wrap around the generic alloc/free calls, or are they tied to memory management within the Motion app underpinnings of mem management?
Right now they're just wrappers around generic alloc/free. We are hoping to make them do something more useful in the future, like freeing caches, etc., but it doesn't yet. (c) Since I don't really understand the internal workings of FCP with respect to Motion-wrapped effect templates, if I try to allocate some memory in my plugin and there is not enough memory, does FCP get a chance to catch this and free up some internal FCP memory before returning NULL and failing, or is all the memory management localized to Motion workings inside of FCP… I ask this since FCP is using the Motion engine and don't quite understand how much FCP is able to work closely with the Motion engine.
Currently, it doesn't do anything fancy like that. Hopefully it will in the future. We've even added a callback to ask the plug-in to free up memory in the future, too. I ask these questions, because we hit lots and lots of out-of-memory conditions in our plugins in FCP 6/7. (It would usefule if the help docs started incorporating answers to these types of questions within the API docs…)
Feel free to file a bug on the docs. We are trying to improve the docs more quickly than in the past.
Darrin
|
_______________________________________________
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