I record a video using the below code and it records perfectly, but when it plays the video, it plays it upside down.
I tried settings mrec.setOrientationHint(
one more solution is to rotate your activity so that its orientation is the same as sensor orientation. That is, landscape for back camera and upside-down portrait for front camera. This btw will not fix mirror effect for the front camera. One more difficulty is that you will have to implement your UI in those rotated activities in a way to follow the activity orientation.