Android camera intent

前端 未结 6 800
旧巷少年郎
旧巷少年郎 2020-11-22 11:47

I need to push an intent to default camera application to make it take a photo, save it and return an URI. Is there any way to do this?

6条回答
  •  夕颜
    夕颜 (楼主)
    2020-11-22 12:36

    try this code

    Intent photo= new Intent("android.media.action.IMAGE_CAPTURE");
                        startActivityForResult(photo, CAMERA_PIC_REQUEST);
    

提交回复
热议问题