Need help to resolve a Fotoapparat library issue.
io.fotoapparat.exception.camera.CameraException: Failed to open camera with lens position: io.fotoapparat.characteristic.LensPosition$Back@31c3b8a2 and id: 0
When I open the first time It will work correctly. But after that, I click on other tabs and then open camera screen It will display a blank white screen. I am using viewPager for that.
How did you initialize FA?
mCameraView = view.findViewById(R.id.camera);
fotoapparat = Fotoapparat.with(getActivity())
.into(mCameraView)
.previewScaleType(ScaleType.CenterCrop)
.logger(new Logger() {
@Override
public void log(String s) {
Log.e("Camera", s);
}
@Override
public void recordMethod() {
}
})
.cameraErrorCallback(new CameraErrorListener() {
@Override
public void onError(CameraException e) {
e.printStackTrace();
fotoapparat.stop();
}
})
.build();
FA version: 2.5.0
Devices/APIs affected: 19,20,21,22