在将其保存到应用程序之前检索捕获的图像
作为 Android 新手,我想知道如何检索从相机捕获的图像(我的应用程序通过意图调用该图像)。
Being new to Android, I want to know how we can retrieve the image captured from the camera (which is being called by my application through intents).
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
请尝试这个
Please try this
桑迪的答案是正确的,但我想添加更多内容,我试图在他的答案中编辑但无法发布 您可以在
onActivityResult()
方法中检查在上面指定的路径处拍摄的新图像,也不要忘记添加
if() 条件来检查 resultCode 是否正确
。像这样,The answer from Sandy is right but I would like to add more, that I tried to edit in his answer but couldn't so posting this
You can check the New Image Taken at the Path specified above in
onActivityResult()
method also Don't Forget to putif() condition to check the resultCode is Ok or not
. like this,