Uri must be non null or empty taking a photo

后端 未结 1 807
失恋的感觉
失恋的感觉 2021-01-29 05:31

Im trying to take a photo when i press my circleimageview, after take the photo crop it and then begin uploading to firebase, the thing is that i press and the camera opens corr

相关标签:
1条回答
  • 2021-01-29 05:46

    Your question does not show the code used to trigger the CAMERA_REQUEST_CODE scenario in onActivityResult().

    Assuming that it is ACTION_IMAGE_CAPTURE, that does not give you a Uri via data.getData(). Instead:

    • If you put EXTRA_OUTPUT on your ACTION_IMAGE_CAPTURE Intent, the image should be in the location that you specified there

    • Otherwise, you get a Bitmap back from data.getParcelableExtra("data")

    0 讨论(0)
提交回复
热议问题