I'm testing on Xperia XZ Android 7.1.1 Api level, and trying to switch the camera during capturing. It gives error on console and keeps freezing.
Session 0: Exception while stopping repeating:
android.hardware.camera2.CameraAccessException: CAMERA_ERROR (3): The camera device has encountered a serious error
at android.hardware.camera2.impl.CameraDeviceImpl.checkIfCameraClosedOrInError(CameraDeviceImpl.java:2023)
at android.hardware.camera2.impl.CameraDeviceImpl.stopRepeating(CameraDeviceImpl.java:952)
at android.hardware.camera2.impl.CameraCaptureSessionImpl.close(CameraCaptureSessionImpl.java:395)
at com.google.android.cameraview.Camera2.stop(Camera2.java:224)
at com.google.android.cameraview.CameraView.stop(CameraView.java:257)
at com.onbranch.onbranchandroidapp.activities.PhotoCheckInActivity.onPause(PhotoCheckInActivity.java:315)
I'm testing on Xperia XZ Android 7.1.1 Api level, and trying to switch the camera during capturing. It gives error on console and keeps freezing. Session 0: Exception while stopping repeating: