Right, I changed that interface this last week, for reasons I explain here.
In short, GPUImageFilters now use cached framebuffers. This means that image capture from them has changed slightly. To make people aware of this, I renamed the methods involved, although perhaps I could have found another way to warn you about this. The new equivalent is -imageFromCurrentFramebufferWithOrientation:
, but before you use that you need to call -useNextFrameForImageCapture
on the filter to indicate that you will be extracting an image the next time this filter runs. This needs to either be called before you use -processImage
on a GPUImagePicture source or right before you use -imageFromCurrentFramebufferWithOrientation:
on a filter pulling from a video source.
This is required, because the framework needs to know to hold onto the cached framebuffer for a little longer than normal, instead of immediately returning it to the cache to conserve memory. This is done for you automatically during photo capture or when using a convenience method like -imageByFilteringImage:
, but needs to be manually triggered when extracting the image like in your code.