Questions tagged [uiimagepickercontroller]

Questions related to the iOS UIImagePickerController class (and the associated UIImagePickerControllerDelegate protocol), which provides system-supplied user interfaces for taking pictures and movies on iOS devices, and for choosing saved images and movies.

Filter by
Sorted by
Tagged with
-1 votes
0 answers
26 views

UIImagePickerController Taking Seconds to Appear

On my app, I have two UIImageViews with interaction enabled. They each initially load with a placeholder image. Tapping them is supposed to open the image picker controller. Selecting an image lets ...
user717452's user avatar
0 votes
0 answers
28 views

Get part of the image taken with default camera

I tried in SwiftUI to create a custom overlay over default camera. I want to get the image only from that square and not the entire image that the camera gets. I managed to get the image in the square,...
user45723's user avatar
  • 113
1 vote
1 answer
73 views

Expo imagepicker pops up twice after permission is granted on iOS

I'm currently using the Expo imagepicker and it works well on Android phones. However, when choosing the "Select Photos" option on iOS, the photo gallery pops up again after permission is ...
ApluUAlberta's user avatar
0 votes
0 answers
46 views

Swift AVAssetExport Session operation stoped

I am trying to export a .wav file from a video file extracted from a UIImagePickerController UIImagePickerController.InfoKey.mediaURL Example url passed in to the function: file:///private/var/...
adalovelacy's user avatar
0 votes
1 answer
43 views

When I pick image from library, the message below always appears. Why? [duplicate]

Error: Publishing changes from background threads is not allowed; make sure to publish values from the main thread (via operators like receive(on:)) on model updates. struct ImagePicker: ...
dunoiww's user avatar
0 votes
0 answers
38 views

When I pick an image using UIImagePickerController, I am presented with AX Lookup problem - errorCode:1100

So firstly, when I present the image picker I get this error: 2023-08-03 16:47:45.979280-0700 MyAppName[7794:1889375] [AXRuntimeCommon] Unknown client: MyAppName Then when I choose an image I get this ...
Mr. Man's user avatar
  • 74
0 votes
0 answers
53 views

Error dismissing image picking and cropping views when using TOCropViewController to pick images in SwiftUI

My Swift app uses TOCropViewController to pick images. The struct which handles the image picking and cropping is called ImagePicker. The view from which ImagePicker is called is a sheet view. When I ...
Nathen Antony's user avatar
0 votes
1 answer
629 views

New PhotosPicker in SwiftUI can open camera instead of the photoLibrary

is there any way to make the new PhotosPicker open the camera instead of opening the photoLibrary, I remember in the old UIImagePickerController there was this option user could choose in the picker ...
Damiano Miazzi's user avatar
0 votes
1 answer
62 views

NSInvalidArgumentException', reason: 'The Live Photo type cannot be specified without the Image media type'

I'm trying to fetch only Live Photos from my gallery for processing tasks. However, the below code gives a runtime crash: let imagePicker = UIImagePickerController() imagePicker....
AnupamChugh's user avatar
  • 1,789
1 vote
1 answer
114 views

why does UIImagePickerController.isSourceTypeAvailable(.camera) return true when using the simulator

why does UIImagePickerController.isSourceTypeAvailable(.camera) return true when using the simulator? This causes the simulator to crash when trying to access the camera.
Halpo's user avatar
  • 3,034
0 votes
0 answers
160 views

UIImagePickerController shows all photos even if I choose "Select Photos.." option Swift

In iOS 14 beta, When I try to access the photos library, it asks for permission the first time, I select "Select Photos.." and select a few photos to show the next time I try to access ...
Sham Dhiman's user avatar
  • 1,396
-1 votes
1 answer
129 views

iOS 16+ devices showing odd titles for camera

My app is already up and running. And things are working fine. But I noticed different titles for camera screen specifically for iOS 16+ devices. I have this simple code that we use for camera no ...
Krutika Sonawala's user avatar
0 votes
0 answers
23 views

How do I reduce lag when loading image with URLSession?

There is a lag in loading the UIImageView called profilePic. How can I get rid of this lag? The problem seems to be in my addImage() method. private func addImage() { let donorId = ...
MartinG's user avatar
0 votes
1 answer
29 views

UIImagePickerController photo edit area

It seems like I can't edit a certain area(mostly top/bottom part) if I use the sourceType == .camera. let picker = UIImagePickerController() picker.sourceType = .camera picker.delegate = self picker....
Ryan's user avatar
  • 4,849
0 votes
1 answer
64 views

Swift XCode Image Picker / Crop Controller Goes Away After Selection and Zooms Out Screen

title. Can't find anything like this bug online and I'm not sure what information I should include other than the methods used. Basically when I hit the plus I go to Add Image, then after selecting an ...
Zach Handley's user avatar
0 votes
0 answers
90 views

How to transfer an Image from one screen to another screen in SwiftUI?

I am creating a feature where a user can take a picture of an item and that image can be displayed on their home screen. I am currently allowing them to take a picture in the AddProductView screen and ...
Abhay Naik's user avatar
0 votes
0 answers
47 views

How to improve quality in terms of readability and resolution for images taken using AVCaptureVideoDataOutput()?

We are using AVCaptureVideoDataOutput() as photo output Instance, to capture images. But there was major reduction in the quality of the image as compared to UIImagePickerController which we were ...
Hrishika Rai's user avatar
0 votes
0 answers
35 views

record video with UIImagePickerController not working while zoom call is active

I'm using UIImagePickerController to record video. It is using fine but when user is on zoom call or sharing the screen the recorder stops and start/stop button stops to respond on user actions. How ...
Mukesh's user avatar
  • 2,812
0 votes
1 answer
592 views

While picking an image from gallery, image_picker is crashing the the app on IOS with no logs in the console

Whenever I click on pick image from gallery using image_picker: ^0.8.6+1 plugin, it opens up the gallery and when I select any image, the app simply crashes with the following message in the console: &...
Haris Raza's user avatar
1 vote
1 answer
123 views

Pick and play a video in SwiftUI — how convert from UIKit code?

I'm working on a camera app and I've got a problem. I've never used UIKit to build an app, but a lot of the reference code does. So I tried to convert it using swiftUI but I failed. There is UIKit ...
Yung Sheng Zeng's user avatar
0 votes
0 answers
22 views

UIImagePickerController - Remember last album

My app allows users to pick images from Photo Library. I use UIImagePickerController for this. User may want to pick image from nested folders and finaly from particular album. When user wants to pick ...
Michal.Jan008's user avatar
0 votes
0 answers
27 views

UIImagePicker returns without an image

Currently I'm using UIImagePickerController to allow our users to take photos within the app like so: UIImagePickerController *picker = [UIImagePickerController new]; picker.sourceType = ...
Mof's user avatar
  • 363
-2 votes
3 answers
541 views

ImagePicker in Flutter

E/flutter ( 6675): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method pickImage on channel plugins.flutter.io/...
Seema Dhami's user avatar
0 votes
0 answers
111 views

Add NavigationBarButton to UIImagePickerController navigation bar

I'm trying to make iOS app and I want to add a UIBarButtonItem to a UIImagePickerController. How can I do that? I tried too many navigaiton bar button operations but it doesn't work. let sampleButton ...
Furkan Hanci's user avatar
0 votes
1 answer
47 views

Picking images from camera and album in iOS Swift 5

I'm working in the application where users will select multiple images from album or taking pictures from camera and send it to server via REST API. Size limit is 5MB for all images. Is there any way ...
Prabhu's user avatar
  • 157
0 votes
0 answers
29 views

In SwiftUI, How to educe size of Image BEFORE saving it in CoreData Attribute "Binary Data" using PhotosPicker [duplicate]

I have a CoreData Entity “GameSession” with an attribute “photo” which is of type “Binary Data” (and I clicked on “Allows External Storage”). In a view, I save a photo in that attribute, like that: ...
user20587286's user avatar
3 votes
0 answers
909 views

Crop Image From Image Picker in SwiftUI

I am using UIImagePickerController to select image from camera or gallery in my SwiftUI app. I set allowsEditing to true. After setting it to true it is showing a square to select the photo like this: ...
Taimoor Arif's user avatar
1 vote
0 answers
1k views

How to get image URL from PHPickerViewController?

I want to select multiple images. Currently I was using UIImagePickerController. However, this does not allow multi-image selection as per this question. So I'm looking into implementing this using ...
Muhammed Mahmood's user avatar
0 votes
2 answers
881 views

Is request permission require for using PHPickerViewController & UIImagePickerController?

I have some confusion about permission with using PHPickerViewController & UIImagePickerController. Do I have to request permission for using it ? (Currently, I open it without request permission ...
Nawin P.'s user avatar
  • 233
1 vote
0 answers
12 views

Segued Image not showing after cancel action on camera?

I am working on a camera iOS application using swift. I'm segueing an image to a view(uploadView) and displaying it using that image on the in camera but when I press the cancel on the camera and ...
kman9's user avatar
  • 11
2 votes
0 answers
323 views

Show user's Selected Image when user accesses photos

I tried to show only photo that I selected before, but it won't work and show all photos. How do I solve this issue? I tried to use permission to limited access but it end up showing all of the photos ...
Sayur Kecambah's user avatar
0 votes
1 answer
197 views

How do you change the cancel button color in a UIImagePickerController?

How do we set the button's tint color in a UIImagePickerController? I've tried setting it with the following, but this changes it for all view controllers: UINavigationBar.appearance().tintColor = ....
dmn's user avatar
  • 21
0 votes
1 answer
300 views

Tap gesture in a view controller causing delay in opening of the view controller when a button in other view controller is pressed

I have implemented a tap gesture on UIStackView in one ViewController which is embedded in a Tab Bar. When I click button on tab bar to open it, it causes a delay of few seconds and then opens the ...
Mel's user avatar
  • 429
3 votes
1 answer
4k views

Fix a warning: [Camera] Attempted to change to mode Portrait with an unsupported device (BackDual)

I have a UICollectionView with a CameraCell in it as a first cell, it displays a camera preview. I want to fix a warning in XCode console on iOS 16, iPhone XS Max with dual rear camera: [Camera] ...
Denis Kutlubaev's user avatar
0 votes
1 answer
357 views

How to save image and text in UITextView in IOS?

I am adding both text and image in UITextView to part of my app ( similar to the notes app ). The user can write a text and/or then select a picture from the photo library or take a picture ( with ...
Dian's user avatar
  • 115
1 vote
0 answers
17 views

Why camera taken picture not showing its preview in profilePicImage.image using UIImagePickerController in swift

I have two images in screen so i am using chooser:ImageChooser here chooser will indicates which button i have clicked with this code if i taken picture from camera then its preview in profilePicImage....
anySwift's user avatar
-1 votes
1 answer
47 views

Why 1st imageview's pic vanishes if i take pic for 2nd imageview in swift

Screen contains two images. here for profilePicImage if i choose from library and for rightProfilePicImg if i take pic with camera then profilePicImage pic vanishes why? how ever if i use library for ...
Json Swift's user avatar
0 votes
1 answer
175 views

get the cgImage from a UIImage that was selected using UIImagePickerController

I am trying to build something for my own learning where I select an image from my photo library then divide that image up into sections. I had found info on how to split a single UIImage into ...
Neglected Sanity's user avatar
1 vote
2 answers
260 views

Can't set the image of a imageView in a customTableViewCell

So in my app I currently have a tableView with custom cells that have an imageView in them. Here is an image for reference to see what It look like and here is the code that defines the custom cell: ...
slimeforest's user avatar
-1 votes
1 answer
45 views

UIImagePickerController.InfoKey does not contain UIImagePickerControllerPHAsset entry when accessing simulators or iPad

I am trying to get all metadata from image files in iPhone and iPad libraries from the photo library. In order to do this I am adding code into the code below which runs after selecting an image from ...
Arthur Rees's user avatar
1 vote
0 answers
134 views

Swift UI: Building a custom image Guess Who game, struggling to access selected images for my Game view

I'm working on my final large portfolio project and I am attempting to create a Guess Who style game in Swift UI that allows you to upload your own images to create custom character cards. I have ...
RyanDelarge's user avatar
1 vote
0 answers
121 views

Automatically Take Picture UIImagePickerController not working in SwiftUI

I want to automatically take an image in my application when the camera is presented. I am using SwiftUI and UIImagePickerController for the camera application. Here is my code for the ImagePicker: ...
Manan Vij's user avatar
  • 111
3 votes
0 answers
450 views

How to record video in SwiftUI and UIImagePickerController

I have been researching for quite a while on how I can create a camera app where the user can take a picture while taking a video (much like in the default camera app). However, I am not able to find ...
Manan Vij's user avatar
  • 111
2 votes
0 answers
191 views

Keeping flash on while Camera is open SwiftUI + UIImagePickerController

I have a UIViewControllerRepresentable struct as follows. struct ImagePicker: UIViewControllerRepresentable { @Binding var isShown: Bool @Binding var image: UIImage? @Binding var ...
Manan Vij's user avatar
  • 111
0 votes
0 answers
501 views

How to unselect an image from Image Picker in SwiftUI

I am creating a message app with SwiftUI. I have made an Image Picker to allow sending photos. Here is the code of my Image Picker : import SwiftUI struct ImagePicker: UIViewControllerRepresentable { ...
Martin's user avatar
  • 3
0 votes
1 answer
165 views

Upload Image to Server with AlamoFire with Absolutely Simple Code

I want to upload selected image to imagePickerController with absolutely the simplest code that I can understand. (I notice answers to similar questions on stackoverflow are still quite long and not ...
Bosco Tsin's user avatar
1 vote
1 answer
1k views

Flutter show date of image when picking an image

I implemented the image_picker inside my app and it is working just fine. However I would like to have a certain feature: I found this on the Once Upon App. As you can see in the screenshot you can ...
Chris's user avatar
  • 1,702
0 votes
2 answers
51 views

How to return an image out of imagePickerController?

I'm new to programming and Swift and I can't find a solution to my problem : I have 4 UIImageView with an UIButton on top of each image. When I tap a UIButton, I want to open an ...
simsab's user avatar
  • 91
0 votes
1 answer
881 views

Selecting only PNG and JPEG in Image picker

I would like to limit the user to only pick a PNG or JPEG image from the photo library. I'm using SwiftUI in my project, this is my UIViewControllerRepresentable struct ImagePickerRaw: ...
Alhomaidhi's user avatar
0 votes
0 answers
80 views

Converting UIKit ImagePicker to SwiftUI

I'm finding it tough to convert this so that it works in a swiftUI view. I have tried my own variations but the function 'getVideofromCameraRoll' which has an 'on' parameter doesn't work in a SwiftUI ...
Anas's user avatar
  • 1

1
2 3 4 5
83