View video frame by frame

Is there a way to step over the video file overs? I tried using VideoView and I had little success. I can get the video step through key frames, but not individual frames. I decided that these would be the default settings, especially with how video compression works. Is there a way to override this default behavior or configuration that I can change?

+6
source share
2 answers

The default behavior in the stagefright media platform always strives for a key frame. (Unlike the earlier framework, opencore, whose default behavior was an attempt to find time).

You cannot search frame by frame using the MediaPlayer API provided by Android.

If you really want to implement frame by frame, then you will have to use a third-party multimedia infrastructure such as FFMPEG, or you will need to implement your own.

+5
source

Have you watched MediaMetadataRetriever ? There you can use getFrameAtTime(long timeUs, int option) and return a Bitmap .

Depending on usage, perhaps this is what you need.

0
source

Source: https://habr.com/ru/post/895274/


All Articles