fix(android): do not change camera rotation while video is being recorded (#2187)

This commit is contained in:
Jose G 2019-04-03 15:20:02 +02:00 committed by Sibelius Seraphini
parent 1168ac95a7
commit 963c249399

View File

@ -557,7 +557,7 @@ class Camera1 extends CameraViewImpl implements MediaRecorder.OnInfoListener,
return;
}
mDeviceOrientation = deviceOrientation;
if (isCameraOpened() && mOrientation == Constants.ORIENTATION_AUTO) {
if (isCameraOpened() && mOrientation == Constants.ORIENTATION_AUTO && !mIsRecording) {
mCameraParameters.setRotation(calcCameraRotation(deviceOrientation));
mCamera.setParameters(mCameraParameters);
}