FlaneurImagePicker is an iOS image picker that allows users to pick images from different sources (ex: user's library, user's camera, Instagram...). It's highly customizable.

Overview

FlaneurImagePicker logo

CI Status Version License Platform Downloads

FlaneurImagePicker is a highly customizable iOS image picker that allows users to pick images from different sources (ex: device's library, device's camera, Instagram...), as used in the Flâneur iOS app.

Features

  • Support for multiple image sources
  • New image sources can easily be added
  • Per-source authorization workflow
  • Customizable UI and behavior

Example

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

Requirements

  • iOS 9
  • Swift 4

Installation

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

pod "FlaneurImagePicker"

Release

To release a version of this pod, please follow these instructions at Cocoapods.

Getting Started

To launch the Flaneur Image Picker:

#import FlaneurImagePicker

let imagePicker = FlaneurImagePickerController(userInfo: nil,
                                               sourcesDelegate: [],
                                               selectedImages: [])
imagePicker.delegate = self
self.present(imagePicker, animated: true, completion: nil)

See the provided example to get a default implementation of the FlaneurImagePickerControllerDelegate protocol.

Property List Keys

Depending on the image sources you intend to integrate, you will need to add values in your app's .plist file for the different sources:

<key>NSCameraUsageDescription</key>
<string>This application needs to access your camera</string>

<key>NSPhotoLibraryUsageDescription</key>
<string>This application needs to access your photo library</string>

<key>InstagramClientID</key>
<string>YOUR_INSTAGRAM_CLIENT_ID</string>

<key>InstagramRedirectURI</key>
<string>YOUR_INSTAGRAM_REDIRECT_URI</string>

Configuration

In order to configure the picker you can use the config object of the picker:

// Changes the cancel button's title
imagePicker.config.cancelButtonTitle = "Cancel"

// Changes the done button's color
imagePicker.config.doneButtonColor = .brown

// Changes the order of the sections
 imagePicker.config.sectionsOrderArray = [.imageSources, .pickerView, .selectedImages]

// Changes the title for the one or more imageSources
imagePicker.config.titleForImageSource = [.instagram: "Insta."]

// Changes height for one or more sections
imagePicker.config.heightForSection = [.selectedImages: Int(UIScreen.main.bounds.height / CGFloat(3)), .imageSources: 50]

// You can find all the possible configurations in the documentation
// as well as an example in the Example directory of the repo
...

Instagram Support

To configure instagram, you need to go on the instagram developer website

  • Create an account
  • Go to the tab "Manage Clients"
  • Register a New Client
  • Fill the information
  • Go back to the tab "Manage Client"
  • Click on the button "Manage"
  • Go to the tab "Security"
  • Uncheck "Disable implicit OAuth"
  • Enter a valid redirect URIs (the redirect URI that you choose doesn't really matter as long as it's an https address, you could use https://google.com for example)
  • Copy the redirectURI in your .plist file (as explained here)
  • Copy the ClientID in your .plist file as explained here)

When you create an account, you are in sandbox mode which means that you can only request the most 20 recents media of the user.

!!! Remember that media means PHOTOS AND VIDEOS, so if you only see 10 photos appearing in the picker, it means either that you only have 10 photos or that the rest of your most recent medias are videos !!!

In oder to test the picker when you're in sandbox mode, you need to add the users as sandbox users, to do so:

  • Go to the tab "Sandbox"
  • Enter the username of the user
  • The user has to go to instagram developer website
  • Create a developer account
  • Go to Sandbox Invites
  • And accept your invitation
  • Then and ONLY THEN he can use the Picker

If you want to leave the Sandbox mode, you need to submit your app to instagram, read the documentation to do so: instagram developer website

Documentation

You can find the documentation in the docs folder of the repository. The master version of the documentation is also available online.

Author

FlaneurApp, [email protected]

Credits

Photo by Joanna Kosinska

License

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

You might also like...
Reconstruct a 3D face with RGB-D images captured by iPhone X's TrueDepth camera.
Reconstruct a 3D face with RGB-D images captured by iPhone X's TrueDepth camera.

!TrueDepth camera can only be accessed on iPhone X or later. TODO Get the RGB-D files (This repository) Generate 3D face mesh with landmark detector a

Highly customizable Action Sheet Controller with Assets Preview written in Swift
Highly customizable Action Sheet Controller with Assets Preview written in Swift

PPAssetsActionController Play with me ▶️ 🖐 If you want to play with me, just tap here and enjoy! 🎩 🕴 Show me 🎪 Try me 📲 The easiest way to try me

Image picker with custom crop rect for iOS written in Swift (Ported over from GKImagePicker)
Image picker with custom crop rect for iOS written in Swift (Ported over from GKImagePicker)

WDImagePicker Ever wanted a custom crop area for the UIImagePickerController? Now you can have it with WDImagePicker. Just set your custom crop area a

A high-performance image library for downloading, caching, and processing images in Swift.
A high-performance image library for downloading, caching, and processing images in Swift.

Features Asynchronous image downloader with priority queuing Advanced memory and database caching using YapDatabase (SQLite) Guarantee of only one ima

React-native-image-generator - Library to generate images from layers
React-native-image-generator - Library to generate images from layers

react-native-image-generator Library for generate images from other images Insta

📸 iMessage-like, Image Picker Controller Provides custom features.

RAImagePicker Description RAImagePicker is a protocol-oriented framework that provides custom features from the built-in Image Picker Edit. Overview O

📹 Your next favorite image and video picker
📹 Your next favorite image and video picker

Description We all love image pickers, don't we? You may already know of ImagePicker, the all in one solution for capturing pictures and selecting ima

FLImagePicker - A simple image picker supported multiple selection
FLImagePicker - A simple image picker supported multiple selection

FLImagePicker A simple image picker supported multiple selection. Features Multiple selection Gesture supported Dark mode Easy modification Installati

Comments
  • Random crashes at view loading time

    Random crashes at view loading time

    When the image picker is presented, we can get random crashes occurring at the following position in emptyView(for:):

        if currentImageSource == nil // No current image source
            || section != .pickerView // The section is not the picker view
            || imageProvider.isAuthorized() // The image provider has already been authorized
        {
            return nil
        }
    

    It seems that imageProvider (declared as a FlaneurImageProvider!) might be nil at this point.

    bug 
    opened by dirtyhenry 2
  • Add filters/compression to photos for preparing uploads

    Add filters/compression to photos for preparing uploads

    We should provide post-selection processing tools to prepare photos for upload.

    This should include:

    • The required size for the upload
    • The required compression format for the upload
    enhancement 
    opened by dirtyhenry 1
  • Smart replacement when only 1 image should be selected

    Smart replacement when only 1 image should be selected

    When the picker is setup to select only 1 image, selecting an image when another is already selected should replace the current selection instead of doing nothing or showing the configured error alert.

    enhancement 
    opened by dirtyhenry 1
Releases(0.7.0)
  • 0.7.0(Mar 12, 2018)

    • Flattened code source files hierarchy under Sources/Classes
    • Renamed FlaneurImageDescription to FlaneurImageDescriptor that is now an enum
    • Created ImageDiffableWrapper as a placeholder for all FlaneurImageDescription's support code
    • Added PreUploadProcessor and the UIImage extension
    Source code(tar.gz)
    Source code(zip)
  • 0.6.0(Feb 21, 2018)

    • Updated FlaneurImageProvider to be more Swifty.
    • Add fetchLimit configuration to FlaneurImageLibraryProvider (defauls to 0 ie fetch everything).
    • Improved remove button #3: new icon button (via FontAwesome) as a replacement to the old text button (as a consequence, removeButtonTitle and removeButtonColor were removed from FlaneurImagePickerConfig).
    Source code(tar.gz)
    Source code(zip)
  • 0.5.0(Jan 18, 2018)

    • Removed the notion of maximum number of selected images, that's been replaced with a new delegation process that allows more flexibility for the caller: dynamically decide if she wants to keep adding to the selection, replacing the last item of the selection or doing nothing.
    • Fixed a crash met randomly at development time that made UI calls from the background thread.
    • Made some code simpler (including the selectedImages' didSet observer).
    • When tapping an image that has already been selected, we scroll back to it to make it obvious why the selection doesn't change.
    • Add logo for iPhone Example app.
    Source code(tar.gz)
    Source code(zip)
Insta-pick - Browse images from reddit with swift

insta-pick Browse images from reddit To run the app: Clone into local folder usi

Just 0 Feb 14, 2022
A Shortcuts-like and highly customizable SFSymbol picker written in Swift.

SFTintedIconPicker SFTintedIconPicker is a Shortcuts-like and highly customizable SFSymbol picker written in Swift. Features Native Appearance Search

StephenFang 2 Aug 16, 2022
An instagram-like image editor that can apply preset filters passed to it and customized editings to a binded image.

CZImageEditor CZImageEditor is an instagram-like image editor with clean and intuitive UI. It is pure swift and can apply preset filters and customize

null 8 Dec 16, 2022
FMPhotoPicker is a modern, simple and zero-dependency photo picker with an elegant and customizable image editor

FMPhotoPicker is a modern, simple and zero-dependency photo picker with an elegant and customizable image editor Quick demo Batch select/deselect Smoo

Cong Nguyen 648 Dec 27, 2022
Vision Camera 📸 The Camera library that sees the vision.

Vision Camera ?? The Camera library that sees the vision. npm i react-native-vision-camera npx pod-install Documentation Guides API Ex

Marc Rousavy 3.5k Jan 5, 2023
Image filtering UI library like Instagram.

Sharaku Usage How to present SHViewController let imageToBeFiltered = UIImage(named: "targetImage") let vc = SHViewController(image: imageToBeFiltered

Makoto Mori 1.5k Dec 20, 2022
Custom iOS camera and photo picker with editing capabilities

Overview Paparazzo is a component for picking and editing photos. Key Features ?? Taking photos using camera ?? Picking photos from user's photo libra

avito.tech 757 Jan 4, 2023
ImageView - Component for loading and displaying different images aka SVG/PNG/JPG/JPEG

ImageView Component that loads and displays images(.svg/.png/.jpg/.jpeg) form as

Sergei 1 Mar 23, 2022
A very useful and unique iOS library to open image picker in just few lines of code.

ImagePickerEasy A very simple solution to implement UIImagePickerController() in your application. Requirements Swift 4.2 and above Installation Image

wajeehulhassan 6 May 13, 2022
ImagePicker - selecting images from the photo albums, with allowed permissions /on real device accesing the camera

ImagePicker - selecting images from the photo albums, with allowed permissions /on real device accesing the camera, permission also needed/after picking an image it has the possibility to rename it

Pavel Surový 0 Jan 26, 2022