Hi everybody,
I am working on a filter that has a setup phase. This setup is started only the first time the filter is applied to a sequence. In this phase all frames of a sequence are retrieved and some parameters obtained from these frames are stored to be used later. After this phase a frame-by-frame processing is done. This logic is implemented in the renderOutput method.
In order to retrieve the frames I am using the FxTemporalImageAPI and FxTimingAPI. The code looks like the following.
........
timingApi= [_apiManager apiForProtocol:@protocol(FxTimingAPI)];
temporalImageAPI= [_apiManager apiForProtocol:@protocol(FxTemporalImageAPI)]; ........
FxBitmap *myBitmap=nil;
double dbg_Duration = [timingApi durationOfInputToFilter:self];
double theTime;
for(theTime=0;theTime<dbg_Duration;theTime+=0.5f)
{
[temporalImageAPI getInputBitmap:&myBitmap withInfo:myRenderInfo atTime:theTime]; Data = "" style="color: #bb2b9f">unsigned char*)[myBitmap dataPtr];
ScanFrame(Data); } [myBitmap release]; ......
This piece of code seems to work properly depending on the footage's format. So far I tested the code with all formats and it seems not to work only for DV-PAL and DV/DVCPRO-NTSC. Only for these two formats I do not get any data from the method getInputBitmap. Does any body had experienced something similar? Is there anything I have to take care of when working with these two formats.
Thanks in advance for any idea.
Best Regards Pablo Robelly
Hotmail: Trusted email with Microsoft’s powerful SPAM protection. Sign up now.
|