An iOS framework that uses the front camera, detects your face and takes a selfie.

Last update: Jun 10, 2022

Build Status CocoaPods Compatible Carthage Compatible License

TakeASelfie

An iOS framework that uses the front camera, detects your face and takes a selfie. This api opens the front camera and draws an green oval overlay on the center of the screen. When a single face has been included in the overlay, selfie automatically will be taken and saved in photo album.

Screenshot

Requirements

TakeASelfie Version Minimum iOS Target Swift Version
0.1.4 11.0 5.x
0.1.3 11.0 4.2
0.1.2 11.0 4.1

Don't forget to add permissions to your application.

  • Privacy - Camera Usage Description (For using camera)
  • Privacy - Photo Library Additions Usage Description (To save captured selfies)
  • Privacy - Photo Library Usage Description - Optional (To display saved selfies from photo album)

CocoaPods

CocoaPods is a dependency manager for Cocoa projects. You can install it with the following command:

$ gem install cocoapods

To integrate TakeASelfie into your Xcode project using CocoaPods, specify it in your Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '11.0'
use_frameworks!

target '
   
    ' do
    pod 'TakeASelfie', '~>0.1.4'
end

   

Carthage

Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.

You can install Carthage with Homebrew using the following command:

brew update
brew install carthage

To integrate TakeASelfie into your Xcode project using Carthage, specify it in your Cartfile:

0.1.4 ">
github "abdullahselek/TakeASelfie" ~> 0.1.4

Swift Package Manager

Modify your Package.swift file to include the following dependency:

.package(url: "https://github.com/abdullahselek/TakeASelfie.git", from: "0.1.4")

Run swift package resolve

XCFramework

XCFrameworks require Xcode 11 or later and integration is very similar to integration of .framework format. Please use script scripts/build-framework.sh to generate binary TakeASelfie.xcframework archive that you can use as a dependency in Xcode.

TakeASelfie.xcframework is a Release (Optimized) binary that offer best available Swift code performance.

Usage

First import library by

import TakeASelfie.

Extend your viewcontroller from SelfieViewDelegate than you can get the event that selfieviewcontroller dismessed.

extension MainViewController: SelfieViewDelegate {

    func selfieViewControllerDismissed() {

    }

}

Instantiate SelfieViewController and present as modal view controller.

let selfieViewController = SelfieViewController(withDelegate: self)
present(selfieViewController, animated: true, completion: nil)

Notes

TakeASelfie uses swiftlint as a linter to check the coding styles and to use a regular style. A script running whnen you build the framework target which invokes the swiftlint with a configuration file located on the root folder.

GitHub

https://github.com/abdullahselek/TakeASelfie
You might also like...

ALCameraViewController - A camera view controller with custom image picker and image cropping.

 ALCameraViewController - A camera view controller with custom image picker and image cropping.

ALCameraViewController A camera view controller with custom image picker and image cropping. Features Front facing and rear facing camera Simple and c

Jun 21, 2022

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

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

Fusuma is a Swift library that provides an Instagram-like photo browser with a camera feature using only a few lines of code.

Jun 7, 2022

This plugin defines a global navigator.camera object, which provides an API for taking pictures and for choosing images from the system's image library.

title description Camera Take pictures with the device camera. AppVeyor Travis CI cordova-plugin-camera This plugin defines a global navigator.camera

Nov 2, 2021

A camera designed in Swift for easily integrating CoreML models - as well as image streaming, QR/Barcode detection, and many other features

A camera designed in Swift for easily integrating CoreML models - as well as image streaming, QR/Barcode detection, and many other features

Would you like to use a fully-functional camera in an iOS application in seconds? Would you like to do CoreML image recognition in just a few more sec

Jun 24, 2022

iOS camera engine with Vine-like tap to record, animatable filters, slow motion, segments editing

iOS camera engine with Vine-like tap to record, animatable filters, slow motion, segments editing

SCRecorder A Vine/Instagram like audio/video recorder and filter framework in Objective-C. In short, here is a short list of the cool things you can d

Jun 16, 2022

A simple, customizable camera control - video recorder for iOS.

A simple, customizable camera control - video recorder for iOS.

LLSimpleCamera: A simple customizable camera - video recorder control LLSimpleCamera is a library for creating a customized camera - video recorder sc

Jun 12, 2022

A light weight & simple & easy camera for iOS by Swift.

A light weight & simple & easy camera for iOS by Swift.

DKCamera Description A light weight & simple & easy camera for iOS by Swift. It uses CoreMotion framework to detect device orientation, so the screen-

May 10, 2022

Camera engine for iOS, written in Swift, above AVFoundation. :monkey:

Camera engine for iOS, written in Swift, above AVFoundation. :monkey:

🌟 The most advanced Camera framework in Swift 🌟 CameraEngine is an iOS camera engine library that allows easy integration of special capture feature

Jun 27, 2022

UIView+CameraBackground - Show camera layer as a background to any UIView.

UIView+CameraBackground - Show camera layer as a background to any UIView.

UIView+CameraBackground Show camera layer as a background to any UIView. Features Both front and back camera supported. Flash modes: auto, on, off. Co

Jan 29, 2022
Comments
  • 1. Added custom camera button

    IMG_1721 Sometimes within seconds a selfie is capturing & sometimes taking 10 to 12 seconds time. So I have added custom camera button to capture the image. Can you please let me know how to capture image on button click.

    Reviewed by KOSURUUDAYSAIKUMAR at 2020-07-22 10:37
  • 2. Camera only opens in portrait mode.

    When the camera opens, it is in portrait mode. My application is purely landscape based. When i put a face infornt of camera, the face is rotated by 90 degrees. How would i open the camera in landscape.

    Reviewed by Travloper at 2019-07-15 11:42
Fasttt and easy camera framework for iOS with customizable filters
Fasttt and easy camera framework for iOS with customizable filters

FastttCamera is a wrapper around AVFoundation that allows you to build your own powerful custom camera app without all the headaches of using AVFounda

May 28, 2022
A Snapchat Inspired iOS Camera Framework written in Swift
A Snapchat Inspired iOS Camera Framework written in Swift

Overview SwiftyCam is a a simple, Snapchat-style iOS Camera framework for easy photo and video capture. SwiftyCam allows users to capture both photos

Jun 26, 2022
Simple Swift class to provide all the configurations you need to create custom camera view in your app

Camera Manager This is a simple Swift class to provide all the configurations you need to create custom camera view in your app. It follows orientatio

Jun 22, 2022
BarcodeScanner is a simple and beautiful wrapper around the camera with barcode capturing functionality and a great user experience.
BarcodeScanner is a simple and beautiful wrapper around the camera with barcode capturing functionality and a great user experience.

Description BarcodeScanner is a simple and beautiful wrapper around the camera with barcode capturing functionality and a great user experience. Barco

Jun 21, 2022
NextLevel is a Swift camera system designed for easy integration, customized media capture, and image streaming in iOS
NextLevel is a Swift camera system designed for easy integration, customized media capture, and image streaming in iOS

NextLevel is a Swift camera system designed for easy integration, customized media capture, and image streaming in iOS. Integration can optionally leverage AVFoundation or ARKit.

Jun 26, 2022
Custom camera with AVFoundation. Beautiful, light and easy to integrate with iOS projects.

?? Warning This repository is DEPRECATED and not maintained anymore. Custom camera with AVFoundation. Beautiful, light and easy to integrate with iOS

May 21, 2022
A fully customisable and modern camera implementation for iOS made with AVFoundation.
A fully customisable and modern camera implementation for iOS made with AVFoundation.

Features Extremely simple and easy to use Controls autofocus & exposure Customizable interface Code-made UI assets that do not lose resolution quality

Jun 6, 2022
Video and photo camera for iOS
Video and photo camera for iOS

Features: Description Records video ?? takes photos ?? Flash on/off ⚡ Front / Back camera ↕️ Hold to record video ✊ Tap to take photo ?? Tap to focus

Jun 14, 2022
VisionCamera Frame Processor Plugin that uses Tensorflow to recognize hand poses

vision-camera-handpose VisionCamera Frame Processor Plugin that uses Tensorflow to recognize hand poses Installation npm install vision-camera-handpos

Nov 9, 2021
Sunny - A weather app, which uses opeanweathermap API
Sunny - A weather app, which uses opeanweathermap API

Sunny It's a weather app, which uses opeanweathermap API. The app recognises the

Feb 1, 2022