Fusuma 0,4,0,6,0,6,3,1 travis-ci CocoaPods

Instagram-like photo browser and a camera feature with a few line of code in Swift.

Fusuma

Fusuma is a Swift library that provides an Instagram-like photo browser with a camera feature using only a few lines of code.
You can use Fusuma instead of UIImagePickerController. It also has a feature to take a square-sized photo.

Version Platform CI Status Carthage compatible codebeat

Preview

Images

Features

  • [x] UIImagePickerController alternative
  • [x] Cropping images in camera roll
  • [x] Taking a square-sized photo and a video using AVFoundation
  • [x] Flash: On & Off
  • [x] Camera Mode: Front & Back
  • [x] Video Mode
  • [x] Colors fully customizable

Those features are available just with a few lines of code!

Installation

Manual installation

Download and drop the 'Classes' folder into your Xcode project.

Using CocoaPods

Add pod 'Fusuma' to your Podfile and run pod install. Also add use_frameworks! to the Podfile.

use_frameworks!
pod 'Fusuma'

Using Carthage

Add github "ytakzk/Fusuma" to your Cartfile and run carthage update. If unfamiliar with Carthage then checkout their Getting Started section.

github "ytakzk/Fusuma"

Fusuma Usage

Import Fusuma import Fusuma then use the following codes in some function except for viewDidLoad and give FusumaDelegate to the view controller.

let fusuma = FusumaViewController()
fusuma.delegate = self
fusuma.hasVideo = true // If you want to let the users allow to use video.
self.presentViewController(fusuma, animated: true, completion: nil)

Delegate methods

// Return the image which is selected from camera roll or is taken via the camera.
func fusumaImageSelected(image: UIImage) {

  print("Image selected")
}

// Return the image but called after is dismissed.
func fusumaDismissedWithImage(image: UIImage) {

  print("Called just after FusumaViewController is dismissed.")
}

func fusumaVideoCompleted(withFileURL fileURL: NSURL) {

  print("Called just after a video has been selected.")
}

// When camera roll is not authorized, this method is called.
func fusumaCameraRollUnauthorized() {

  print("Camera roll unauthorized")
}

Colors

fusumaTintColor: UIColor // tint color

fusumaBackgroundColor: UIColor // background color

Customize Image Output

You can deselect image crop mode with:

fusumaCropImage:Bool // default is true for cropping the image 

Fusuma for Xamarin

Cheesebaron developed Chafu for Xamarin.
https://github.com/Cheesebaron/Chafu

Author

ytakzk
http://ytakzk.me

Donation

Your support is welcome through Bitcoin 16485BTK9EoQUqkMmSecJ9xN6E9nhW8ePd

License

Fusuma is released under the MIT license.
See LICENSE for details.

Related Repositories

awesome-swift

awesome-swift

A collaborative list of awesome swift resources. Feel free to contribute! ...

awesome-swift

awesome-swift

A curated list of awesome Swift frameworks, libraries and software. ...

iOSRepo

iOSRepo

A list of resources & libraries for iOS and Swift. ...

awesome-swift

awesome-swift

A collaborative list of awesome swift resources. Feel free to contribute! ...

ios-dev

ios-dev

ios开发用到的插件或教程等 ...


Top Contributors

ytakzk waterskier2007 michaelbina Ferrick90 pruthvikar saugat135 geitoodevs lexrus floler glancashire reeichert Shrugs muhasturk ReadmeCritic korzonek 5d

Releases

-   1.0.0 zip tar
-   0.6.0 zip tar
-   0.5.3 zip tar
-   0.5.2 zip tar
-   0.5.1 zip tar
-   0.5.0 zip tar
-   0.4.1 zip tar
-   0.4.0 zip tar
-   0.3.8 zip tar
-   0.3.7 zip tar
-   0.3.6 zip tar
-   0.3.5 zip tar
-   0.3.4 zip tar
-   0.3.3 zip tar
-   0.3.2 zip tar
-   0.3.1 zip tar
-   0.3.0 zip tar
-   0.2.8 zip tar
-   0.2.7 zip tar
-   0.2.6 zip tar
-   0.2.5 zip tar
-   0.2.4 zip tar
-   0.2.3 zip tar
-   0.2.2 zip tar
-   0.2.1 zip tar
-   0.2.0 zip tar
-   0.1.91 zip tar
-   0.1.9 zip tar
-   0.1.8 zip tar
-   0.1.7 zip tar