Giter VIP home page Giter VIP logo

corephotopickervcmanager's Introduction

Charlin出框架的目标:简单、易用、高度封装、绝对解耦!

#CorePhotoPickerVCManager ####大统一的多功能照片选取器,集成拍摄,单选,多选。

##框架特性:

1.无需代理,无需解析数据,传一个type值,block就把图片对象给你!
2.支持相册目录(后期支持视频选取)。
3.支持iPhone6/iPhone6 Plus及横竖屏。
4.支持相册直接拍摄、相册选取(单选),相册多选
5.相册多选支持最少选取张数,最多选取张数,并带有超出选取自动提示。
6.界面专业设计,界面美观。
7.支持设备不可用block回调。
8.整个使用过程你不再需要设置代理,全部使用block回调。
9.您如果需要不同的选取功能,直接在初始化的时候指定type即可

##重要定义: typedef enum{

        //用户拍照
        CorePhotoPickerVCMangerTypeCamera=0,
        
        //单张照片选取
        CorePhotoPickerVCMangerTypeSinglePhoto,
        
        //多张照片选取
        CorePhotoPickerVCMangerTypeMultiPhoto,
        
        //视频选取(暂不考虑,本框架仍可以完美支持)
        CorePhotoPickerVCMangerTypeVideo,

}CorePhotoPickerVCMangerType;


typedef enum{

        //无错误,可用
        CorePhotoPickerUnavailableTypeNone,
        
        //相机不可用
        CorePhotoPickerUnavailableTypeCamera,
        
        //相册不可用
        CorePhotoPickerUnavailableTypePhoto,
        
}CorePhotoPickerUnavailableType;

#使用示例:

CorePhotoPickerVCManager *manager=[CorePhotoPickerVCManager sharedCorePhotoPickerVCManager];

//设置类型
manager.pickerVCManagerType=type;

//最多可选3张
manager.maxSelectedPhotoNumber=3;

//错误处理
if(manager.unavailableType!=CorePhotoPickerUnavailableTypeNone){
    NSLog(@"设备不可用");
    return;
}

UIViewController *pickerVC=manager.imagePickerController;

//选取结束
manager.finishPickingMedia=^(NSArray *medias){
    
    [medias enumerateObjectsUsingBlock:^(CorePhoto *photo, NSUInteger idx, BOOL *stop) {
        NSLog(@"%@",photo.editedImage);
    }];
};

[self presentViewController:pickerVC animated:YES completion:nil];

#看看效果图吧: image image image






CorePhotoPickerVCManager 大统一的多功能照片选取器,集成拍摄,单选,多选。



版权说明 RIGHTS

作品说明:本框架由iOS开发攻城狮Charlin制作。
作品时间: 2015.01.02 23:50
更新时间: 2015.03.03 15:14

关于Chariln INTRODUCE

作者简介:Charlin-四川成都华西都市报旗下华西都市网络有限公司技术部iOS工程师!

联系方式 CONTACT

Q Q:1761904945(请注明缘由)
Mail:[email protected]

corephotopickervcmanager's People

Contributors

charlinfeng avatar

Watchers

gryphon avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.