Latest 0.1.2
Homepage https://github.com/buhikon/JLImagePicker
License MIT
Platforms ios 8.0
Authors

[![CI Status](http://img.shields.io/travis/Joey Lee/JLImagePicker.svg?style=flat)](https://travis-ci.org/Joey Lee/JLImagePicker)
Version
License
Platform

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

Installation

JLImagePicker is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "JLImagePicker"

Setting

Add privacy key-string pairs in Info.plist file for your target.

  • Example
    <key>NSCameraUsageDescription</key>
    <string>This app requires access to the camera.</string>
    <key>NSPhotoLibraryUsageDescription</key>
    <string>This app requires access to the photo library.</string>

Usage

  • Objective-C
    
    #import <JLImagePicker/JLImagePicker.h>

[JLImagePicker takePhotoOnViewController:self.viewController
camera:JLImagePickerCameraFront
allowsEditing:YES
completion:^(BOOL success, UIImage *image, AVAuthorizationStatus authStatus) {
if(success) {
// do something with the image
}
else {
if(authStatus == AVAuthorizationStatusRestricted) {
// alert
}
else if(authStatus == AVAuthorizationStatusDenied) {
// alert + go to Settings app
}
}
}];

- Swift 4

import JLImagePicker

JLImagePicker.takePhoto(on: viewController, camera: .front, allowsEditing: true) { (success, image, authStatus) in
if success {
// do something with the image
}
else {
if authStatus == .restricted {
// alert
}
else if authStatus == .denied {
// alert + go to Settings app
}
}
}



## Author

Joey Lee, [email protected]

## License

JLImagePicker is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "JLImagePicker",
    "version": "0.1.2",
    "summary": "A simple image picker from camera or album.",
    "description": "super easy to pick a photo from front camera, rear camera or album.",
    "homepage": "https://github.com/buhikon/JLImagePicker",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Joey Lee": "[email protected]"
    },
    "source": {
        "git": "https://github.com/buhikon/JLImagePicker.git",
        "tag": "0.1.2"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source_files": "JLImagePicker/Classes/**/*"
}

Pin It on Pinterest

Share This