Camera picture Uri null path

后端 未结 1 1961
臣服心动
臣服心动 2021-01-26 10:09

In my app, I let the user the chance to get a photo and set it as profile pic. There are 2 ways for getting the photo, from the gallery, and directly taken with the camera.

相关标签:
1条回答
  • 2021-01-26 10:45

    So I know that it must be something with the path.

    That's because it's not a filesystem path. A Uri is not a file, and while you are handling that properly elsewhere, you are not doing so here.

    You need to switch to EXIF logic that can handle an InputStream, such as this code culled from the AOSP Mms app.

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