Samsung MediaRecorder correct video recording

I am trying to run a Google sample to record a 10 second video using MeadiaRecorder inside my application. But when playing videos, it becomes corrupt.

  • Firstly, it reproduces the full sound;
  • Then plays the first first frame of the video;
  • The video freezes and nothing happens.

When I looked at the file in Explorer, it showed a length of up to 59 minutes, while I saved only 10 seconds, and the video also did not play when I tried to play it on a computer.

I use the https://github.com/googlesamples/android-Camera2Video library as a sample and run the same code through the device without any changes.

It works great on all other devices except Samsung devices (J7, S5, S6, S8, etc.)

There is an open problem in the above library, but still no solution is provided there.

+5
source share

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


All Articles