是否可以通过UIImagePickerController访问iPad库中相册中文件夹内的图像
谢谢, 克里斯蒂
答案 0 :(得分:3)
请改用:
imagePicker.sourceType = UIImagePickerControllerSourceTypeSavedPhotosAlbum
答案 1 :(得分:1)
是!
imagePicker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
答案 2 :(得分:1)
这里是代码......只需创建一个按钮...... n从你想要的任何地方(模态或视图)中选择所需的图像 你也可以使用
访问相机照片picker.sourceType = UIImagePickerControllerSourceTypeCamera;
-(IBAction) getPhoto:(id) sender {
UIImagePickerController * picker = [[UIImagePickerController alloc] init];
picker.delegate = self;
if((UIButton *) sender == choosePhotoBtn) {
picker.sourceType = UIImagePickerControllerSourceTypeSavedPhotosAlbum;
}
[self presentModalViewController:picker animated:YES];
}