uiimagepickercontroller

Getting a URL from (to) a “picked” image, iOS

房东的猫 提交于 2019-12-24 08:01:56
问题 With this code below, I can extract metadata from an image (pre-added to my project), and render the info as text. This is exactly what I want to do. The SYMetadata is created by pointing to an image via URL. initWithAbsolutePathURL . I want to do the same thing with a UIImage or maybe the image that is being loaded to the UIImage. How do I get the URL to the image that the picker selects? Or how do I create an "asset" from this incoming image? The documentation describes initWithAsset . Have

iphone uiimagepickerViewController choosing photolibrary video

落爺英雄遲暮 提交于 2019-12-24 06:03:47
问题 Am developing a application which is only selecting video form local photo library and sending it to the server. Here am fixed videoMaximumDuration as 1min..(bcoz am restricting user to choose video less than 1min). when user choosing more than 1min video in uiimagepickerviewcontroller a text is appearing that 'Video Too Long to Send - Please select similar form video' Here while this text is appearing i want to disable or hide the 'Choose' button which is there in bottom of

Why is the status bar sliding back of 20 points my image when I hide it?

筅森魡賤 提交于 2019-12-24 04:56:33
问题 There appears to be a bug when UIImagePickerController gets called. The status bar shows up even it shouldn't. To workaround that am using subclassing it: class MyImagePickerController: UIImagePickerController { override func viewWillAppear(animated: Bool) { super.viewWillAppear(animated) self.setNeedsStatusBarAppearanceUpdate() } override func prefersStatusBarHidden() -> Bool { return true } override func childViewControllerForStatusBarHidden() -> UIViewController? { return nil; } } and I

MPMoviePlayerController doesn't play newly saved video file

拈花ヽ惹草 提交于 2019-12-24 02:48:09
问题 I'm using an imagePickerController to record video. In the imagePickerController:didFinishPickingMediaWithInfo: function I'm trying to set the video to a previously defined MPMoviePlayerController: if ([mediaType isEqualToString:(NSString *)kUTTypeMovie]){ NSURL *movieUrl = [info objectForKey:UIImagePickerControllerMediaURL]; [self.moviePlayer setContentURL:movieUrl]]; } This is working fine and the video is indeed playing. But I want to save the file for later use. When I do this and use the

UIImagePickerController occasionally freezing up

戏子无情 提交于 2019-12-24 02:34:09
问题 I use UIImagePickerController in an Unity app. It occasionally freezes when the user presses "done". It happens most often on 3GS — about every third time — but I also had an occasional freeze on iPhone 5. This bug appears on iOS from 4.3 to 7.0. I wasn't able to determine what factors correlate with the freeze. I don't get a memory warning when I get this freeze either. There are no errors in the log, no crashlog whatsoever. The app continues to run behind UIImagePickerController as normal.

how to prevent saving picture from camera roll again

末鹿安然 提交于 2019-12-23 19:16:24
问题 May be this question is too easy or I did not know how easy it will be. I have an actionsheet to allow the user to choose how if they want to take a photo or select from camera. The app will save user taken photo regardless is selected from camera roll or taken from camera. Am I missing something? Thanks for reading my question. #pragma mark - photo select -(IBAction)showCameraAction:(id)sender { if(![UIImagePickerController isSourceTypeAvailable: UIImagePickerControllerSourceTypeCamera]) {

AVCaptureSession VS UIImagePickerController camera preview

大城市里の小女人 提交于 2019-12-23 18:04:09
问题 I'm developing an application similar to Instagram iOS app. Instagram have a custom camera preview. I want to develop something similar and the question is - what to use better for this purpose - UIImagePickerController with custom cameraOverlayView property or should I use AVCaptureSession ? Maybe someone have such experience and can give me an advice. Will be appreciate. 回答1: AVCaptureSession is more customisable than UIImagePickerController. In case of speed, there is not much difference.

UIImagePickerController InterfaceOrientation Crash

◇◆丶佛笑我妖孽 提交于 2019-12-23 16:28:09
问题 Ever since updating my device to 6.1, I'm getting a crash when trying to show the UIImagePickerController. I only use Portrait orientation. The Crash: Reason: * Terminating app due to uncaught exception 'UIApplicationInvalidInterfaceOrientation', reason: 'preferredInterfaceOrientationForPresentation must return a supported interface orientation!' Here is where I call the UIImagePickerController: if (![UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera]) { /

How to write orientation data to the UIImage iOS SDK

橙三吉。 提交于 2019-12-23 12:50:09
问题 I have a problem i got a UIImage from imagePicker (camera not library) but when i write it to file with [UIImageJPEGRepresentation writeToFile: atomically:] i'm loosing orientation data(all images are in landscape), i used some code with image transformation, but it take too long about 1,5 - 2 sec per image, my question is how to not loose orientation ? Maybe i can write it to EXIF data ? Thx for help. EDIT: Thx to Jonathan Cichon, now i got a image orientation with

Is it possible to share an image via UIActivityViewController and retain exif data?

血红的双手。 提交于 2019-12-23 10:57:04
问题 I have an app which saves images to a custom album within the camera roll via [library writeImageToSavedPhotosAlbum:[newTestImage CGImage] metadata:metadata completionBlock:^(NSURL *assetURL, NSError *error) { //error } ]; This works fine, however, I would then like to allow the user to share these images from within the app, I was doing it via ALAsset *assetToShare = self.images[indexPath.row]; NSString *stringToShare = @"….."; NSArray *dataToShare = @[assetToShare, stringToShare];