How to know if iPhone camera is ready to take picture?

后端 未结 7 1924
清酒与你
清酒与你 2020-12-05 06:54

When [camera takePicture] is called before the camera is ready, it spits out this message:

UIImagePickerController: ignoring request to take pictu

7条回答
  •  执念已碎
    2020-12-05 07:46

    This makes sure to start capturing video as soon as camera is ready

    imgpicker = [[UIImagePickerController alloc] init];  
    [self presentViewController:imgpicker animated:YES completion:^(void){       
    while(![imgpicker startVideoCapture]);
    }];
    

提交回复
热议问题