IOS拍照控件同时显示拍照与录像
来源:网络 责任编辑:栏目编辑 发表时间:2013-07-01 06:17 点击:次
- (void) recordVideo: (id) sender
{
UIImagePickerController *ipc = [[UIImagePickerController alloc] init];
ipc.sourceType = UIImagePickerControllerSourceTypeCamera;
ipc.delegate = self;
ipc.allowsEditing = YES;
www.2cto.com
ipc.videoQuality = UIImagePickerControllerQualityTypeMedium;
ipc.videoMaximumDuration = 30.0f; // 30 seconds
///ipc.mediaTypes = [NSArray arrayWithObject:@"public.movie"];
//主要是下边的两能数,@"public.movie", @"public.image" 一个是录像,一个是拍照
ipc.mediaTypes = [NSArray arrayWithObjects:@"public.movie", @"public.image", nil];
[self presentModalViewController:ipc animated:YES];
}
摘自 阿华的博客
{
UIImagePickerController *ipc = [[UIImagePickerController alloc] init];
ipc.sourceType = UIImagePickerControllerSourceTypeCamera;
ipc.delegate = self;
ipc.allowsEditing = YES;
www.2cto.com
ipc.videoQuality = UIImagePickerControllerQualityTypeMedium;
ipc.videoMaximumDuration = 30.0f; // 30 seconds
///ipc.mediaTypes = [NSArray arrayWithObject:@"public.movie"];
//主要是下边的两能数,@"public.movie", @"public.image" 一个是录像,一个是拍照
ipc.mediaTypes = [NSArray arrayWithObjects:@"public.movie", @"public.image", nil];
[self presentModalViewController:ipc animated:YES];
}
摘自 阿华的博客
相关新闻>>
- 发表评论
-
- 最新评论 更多>>