CameraView
CameraView copied to clipboard
Cameraoptions not set after onCameraAvailable super call
- [x] I am using the latest version
- [ ] I can reproduce the bug in the demo app, and if not...
- [ ] I have tried to reproduce the bug in the demo app
Detailed steps to reproduce the issue:
- In activity onStart, add a CameraListener which implements onCameraOpened
- In the onCameraOpened function, first call super.onCameraOpened
- Next, try to access cameraView.cameraOptions.supportedFlash
Expected behavior:
Should contain an array of supported flash modes as we've received the CameraOptions from the camera and it should have them set internally as well.
Actual behavior:
SOMETIMES crashes with a nullpointer on cameraOptions.
When I put some logs before the accessing of cameraView.cameraOptions, i didn't manage to crash it.
I don't know why your cameraOptions object would be null, but looks like an application issue. I'm closing becauase there are lots of issues to review, feel free to reopen with more info if you have