I have not yet used FFmpegFrameGrabber before, but I use ffmpeg JNI writed by myself. My solution is:
- Get frame data (NV21 or BGR24) by ffmpeg.
- Process the frame data by my image / video processing algorithm.
- Upload frame data to GPU as OpenGL texture.
- Display data by OpenGL fragment shader in a fullscreen rectangle.
I have another idea if the 2th operation can be written in GPU shader (Many real-time camera effects in mobile are done by this method). You can use MediaPlayer instead of ffmpeg. And write GPU shader for SurfaceTexture.