how to flip the video taken using front camera and

2019-09-15 04:50发布

问题:

This question already has an answer here:

  • Android flip front camera mirror flipped video 4 answers

I have a video that mirror flips when I take it using the front camera.

The surface view that is used to capture the video shows the mirror effect when recording but then it is flipped while playing the same.

Kindly Help me.

回答1:

This is an expected behavior. You cannot run the video recorder mirrored. You can flip the frames yourself (receiving the frames in onPreviewFrame callback) and use MediaCodec and her kin to produce a video file on your own. Or you can post-process your video, e.g. with ffmpeg.