SDK Version: 38.0.8 Platforms(Android/iOS/web/all): Android
Expo standalone android app crashes with face detector error: Illegal argument exception: Invalid image data size
The image shows the error I get once my app crashes.
<Camera
style={styles.camera}
type={this.state.type}
ratio="16:9"
pictureSize="16:9"
flashMode={Camera.Constants.FlashMode.auto}
onFacesDetected={this.handleFacesDetected}
faceDetectorSettings={{
mode: FaceDetector.Constants.Mode.fast,
detectLandmarks: FaceDetector.Constants.Landmarks.all,
runClassifications:
FaceDetector.Constants.Classifications.all,
tracking: true,
}}
How can I add some kind of error catching to the onFacesDetected function in the camera module.