Skip to content

A Snapchat Inspired iOS Camera Framework written in Swift

License

Notifications You must be signed in to change notification settings

DarkySwift/LittleOwl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LittleOwl

Build Status Cocoa Pod Carthage compatible Language: Swift codecov Platform License: MIT Author: carlos21

Requirements

  • Swift 3.2 or later
  • iOS 8.0 or later
  • Insert github "DarkySwift/LittleOwl" ~> 1.0 to your Cartfile.
  • Run carthage update.
  • Link your app with LittleOwl in Carthage/Build.
  • Insert pod 'LittleOwl', '~> 1.0' to your Podfile.
  • Run pod install.

Prerequisites:

As of iOS 10, Apple requires the additon of the NSCameraUsageDescription and NSMicrophoneUsageDescription strings to the info.plist of your application. Example:

<key>NSCameraUsageDescription</key>
<string>To Take Photos and Video</string>
<key>NSMicrophoneUsageDescription</key>
<string>To Record Audio With Video</string>

Getting Started:

If you install SwiftyCam from Cocoapods, be sure to import the module into your View Controller:

import LittleOwl

LittleOwl is a drop-in convenience framework. To create a Camera instance, just add this:

let cameraController = CameraViewController(type: .video(10))
cameraController.didSelectVideo = { url in
    cameraController.dismiss(animated: true, completion: nil)
}

or

let cameraController = CameraViewController(type: .photo)
cameraController.didSelectPhoto = { image in
    cameraController.dismiss(animated: true, completion: nil)
}

Image 1 Image 2

That is all that is required to setup the AVSession for photo and video capture. LittleOwl will prompt the user for permission to use the camera/microphone, and configure both the device inputs and outputs.

Author

Carlos Duclós

License

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

About

A Snapchat Inspired iOS Camera Framework written in Swift

Resources

License

Stars

Watchers

Forks

Packages

No packages published