Log in

View Full Version : A question about using "InternalCache"


MrTibs
24th March 2004, 21:26
Sorry but I have another dumb question...

Will the InternalCache function allow me to store frames in memory that I can use over an over again? (Without having to fetch it from the filter chain every time the filter is called.)

For example, in my NoLogo filter, I fetch a frame to use as my mask. Every time I remove the logo, I need to fetch the same frame. Could I use InternalCache to fetch the frame once (when the filter is created) and simply re-use it from cache for the entire video sequence?

This is important because I will be overwriting the original fetched frame later so I need a cached copy of the mask.

sh0dan
24th March 2004, 21:57
You should only use InternalCache, when you are invoking filters (env->Invoke(...)) in your filter, otherwise it is fairly safe to assume that your frame is already cached.

Are you always requesting the same framenumber for your mask? If yes, then you can assume it is cached.

MrTibs
24th March 2004, 22:10
Thanks for the quick reply Sh0dan.

I'll give it a try.