[Solved] How I could access to the Url of photo saved in the camera roll


Your question is extremely vague with nothing for us to work with. But in any case, I just created an app requiring that logic so I would just share with you

func imagePickerController(picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String : AnyObject]) {

    // Clear data if picture is repicked

    imageLocalURL = nil
    imageData = nil

    imageSelected = info[UIImagePickerControllerOriginalImage] as? UIImage

    if info[UIImagePickerControllerReferenceURL] != nil {

        // This would mean that image is chosen from photo library

        referenceURL = info[UIImagePickerControllerReferenceURL] as? NSURL
        let assets = PHAsset.fetchAssetsWithALAssetURLs([referenceURL! as NSURL], options: nil)
        let asset = assets.firstObject
        asset?.requestContentEditingInputWithOptions(nil, completionHandler: { (contentEditingInput, info) in
                    // This would be the URL of your image in photo library
                    self.imageLocalURL = contentEditingInput?.fullSizeImageURL

    } else {

        // This means that image is taken from camera

        imageData = UIImageJPEGRepresentation(imageSelected!, 1.0)

    }

    dismissViewControllerAnimated(true, completion: nil)
}

1

solved How I could access to the Url of photo saved in the camera roll