iOS从相册和相机选择图片进行封装

3997
    


来源:
Licence:
联系:
分类:
平台:
环境:
大小:
更新:
标签:
联系方式 :
免费下载 ×

下载APP,支持永久资源免费下载

限免产品服务请联系qq:1585269081

下载APP
免费下载 ×

下载APP,支持永久资源免费下载

下载APP 免费下载
下载 ×

下载APP,资源永久免费


如果出现不能下载的情况,请联系站长,联系方式在下方。

免费下载 ×

下载论文助手APP,资源永久免费

免费获取

如果你已经登录仍然出现不能下载的情况,请【点击刷新】本页面或者联系站长



WHC_PhotoCameraChoicePictureDemo 作者:吴海超 联系qq:712641411 iOS从相册和相机选择图片进行封装,从相册支持选择多张和一张控制,集成使用简单方便,具体看demo使用集成方式

运行效果 接口使用实例 Use Example - ( IBAction )clickButton:(UIButton *)sender{ switch (sender. tag ) { case 0 :{ //从相册选择一张 WHC_PictureListVC * vc = [WHC_PictureListVC new ]; vc. delegate = self; vc. choiceMorePicture = NO ; [ self presentViewController: [[UINavigationController alloc ]initWithRootViewController:vc] animated: YES completion: nil ]; } break ; case 1 :{ //从相册选择多张 WHC_PictureListVC * vc = [WHC_PictureListVC new ]; vc. delegate = self; vc. choiceMorePicture = YES ; [ self presentViewController: [[UINavigationController alloc ]initWithRootViewController:vc] animated: YES completion: nil ]; } break ; case 2 :{ //从相机选择 WHC_CameraVC * vc = [WHC_CameraVC new ]; vc. delegate = self; [ self presentViewController: vc animated: YES completion: nil ]; } break ; default : break ; } } //下面是代理实现在代理里面显示所选图片 # pragma mark - WHC_ChoicePictureVCDelegate - ( void )WHCChoicePictureVC:(WHC_ChoicePictureVC *)choicePictureVC didSelectedPhotoArr:( NSArray *)photoArr{ for (UIView * subView in _imageSV. subviews ) { if ([subView isKindOfClass: [UIImageView class ]]){ [subView removeFromSuperview ]; } } for ( NSInteger i = 0 ; i < photoArr. count ; i++) { UIImageView * imageView = [[UIImageView alloc ]initWithFrame: CGRectMake (i * CGRectGetWidth (_imageSV.frame), 0 , CGRectGetWidth (_imageSV.frame), CGRectGetHeight (_imageSV.frame))]; imageView. image = photoArr[i]; [_imageSV addSubview: imageView]; } _imageSV. contentSize = CGSizeMake (photoArr. count * CGRectGetWidth (_imageSV. frame ), 0 ); } # pragma mark - WHC_CameraVCDelegate - ( void )WHCCameraVC:(WHC_CameraVC *)cameraVC didSelectedPhoto:(UIImage *)photo{ [ self WHCChoicePictureVC: nil didSelectedPhotoArr: @[photo]]; }



免费下载 ×

下载APP,支持永久资源免费下载

下载APP 免费下载
温馨提示
请用电脑打开本网页,即可以免费获取你想要的了。
扫描加我微信 ×

演示

×
登录 ×


下载 ×
论文助手网
论文助手,最开放的学术期刊平台
				暂无来源信息			 
回复
来来来,吐槽点啥吧

作者联系方式

×

向作者索要->