网站建设资讯

NEWS

网站建设资讯

ios调用摄像头默认为摄像

            if(![UIImagePickerControllerisSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera])

目前创新互联公司已为上1000+的企业提供了网站建设、域名、虚拟空间、网站托管运营、企业网站设计、张家界网站维护等服务,公司将坚持客户导向、应用为本的策略,正道将秉承"和谐、参与、激情"的文化,与客户和合作伙伴齐心协力一起成长,共同发展。

            {

                UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"错误提示" message:@"没有发现摄像头" delegate:self cancelButtonTitle:@"确定" otherButtonTitles:nil];

                [alert show];

                return;

            }

           UIImagePickerController *pickerVideo = [[UIImagePickerControlleralloc]init];

            pickerVideo.sourceType =UIImagePickerControllerSourceTypeCamera;

            pickerVideo.delegate = self;

            pickerVideo.allowsEditing = YES;

            pickerVideo.videoQuality = 2;

            pickerVideo.videoMaximumDuration = 60.0f;

            pickerVideo.cameraDevice =UIImagePickerControllerCameraDeviceFront;

            pickerVideo.mediaTypes = [NSArray arrayWithObject:@"public.movie"];

            [selfpresentViewController:pickerVideoanimated:YEScompletion:nil];


标题名称:ios调用摄像头默认为摄像
新闻来源:http://cdweb.net/article/josiei.html