Building my own camera application + Automatically capture the image

后端 未结 3 792
一整个雨季
一整个雨季 2021-02-01 00:06

I have created my own camera application. And when I click the button it takes the picture and saves it in the galary. What I want to do is to take the picture without a preview

3条回答
  •  梦毁少年i
    2021-02-01 00:23

    Ok I found a answer to take the picture automatically. Adding as a comment for the use of others.

    final Timer t = new Timer();
    t.schedule(new TimerTask() { 
    @Override 
    public void run() { 
    mCamera.takePicture(null, null, mPicture); t.cancel(); 
    } 
    },5000);
    

提交回复
热议问题