uiimagepickercontroller

iPhone: Get camera preview

可紊 提交于 2019-11-28 06:07:22
I'd like to get the image that is being displayed on the UIImagePickerController when user uses the camera. And when I get I want to process the image and display instead of regular camera view. But the problem is when I want to get the camera view, the image is just a black rectangle. Here's my code: UIView *cameraView = [[[[[[imagePicker.view subviews] objectAtIndex:0] subviews] objectAtIndex: 0] subviews] objectAtIndex: 0]; UIGraphicsBeginImageContext( CGSizeMake(320, 427) ); [cameraView.layer renderInContext: UIGraphicsGetCurrentContext()]; UIImage *viewImage =

iPhone Get UIImagePickerController Lat/Lng

我的未来我决定 提交于 2019-11-28 06:02:49
I'm using the UIImagePickerController to take a photo and then upload the photo to a WCF Service . Along with the image, I also need to send to the latitude and longitude of the photo. How can I get hold of this information from the photo taken? I've searched online but can't seem to find a good source of info. I've seen about the EXIF data that is passed through the UIImagePickerControllerMediaMetadata key as part of the didFinishPickingMediaWithInfo delegate method. However, when I print out the contents to the log, there's no location information. Am I missing something, do I need to turn

iOS 4.3 changed transformation on UIImagePickerController's camera overlay view

心已入冬 提交于 2019-11-28 05:39:13
问题 After testing my App on iOS 4.3 I noticed that the camera overlay of my UIImagePickerController has an added transformation that stretched the content extremely. Pre iOS 4.3 everything shows up correctly. Here is what I do imagePicker = [[UIImagePickerController alloc] init]; imagePicker.delegate = self; imagePicker.sourceType = UIImagePickerControllerSourceTypeCamera; cameraOverlay = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 200, 200)]; cameraOverlay.backgroundColor = [UIColor

How do I get the data from UIImagePickerControllerReferenceURL?

我与影子孤独终老i 提交于 2019-11-28 05:07:54
I am using ELCImagePickerController in my app and I don't want to save the selected fullScreenImage to my array because if i selected 40 iPad images then that is not good. I want to get data from UIImagePickerControllerReferenceURL instead of UIImagePickerControllerOriginalImage from the dict of method - (void)elcImagePickerController:(ELCImagePickerController *)picker didFinishPickingMediaWithInfo:(NSArray *)info . I have tried: NSDictionary *dict = [info objectAtIndex:count]; NSData *data = [NSData dataWithContentsOfURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@",[dict objectForKey

UIImagePickerController in iOS 7 status bar

眉间皱痕 提交于 2019-11-28 04:44:09
问题 In io7,the status bar on top a view is a nightmare.Fortunally i managed to make it work so it will be placed above the view.I did it like this: - (void)viewDidLoad { [super viewDidLoad]; if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) { self.view.backgroundColor=[UIColor colorWithRed:(152/255.0) green:(204/255.0) blue:(51/255.0) alpha:1] ; CGRect frame = self.topNav.frame; frame.origin.y = 20; self.topNav.frame = frame; } .... } Now my status bar is above my navigation bar.

How to adjust a image size after using UIImagePickerController take a photo?

谁说我不能喝 提交于 2019-11-28 04:22:39
问题 How to resize a image when save photo in document folder ??? This is how I save an image in iphone. NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *imageFile = nil; NSString *name_png = [NSString stringWithFormat:@"%@.png",photoName]; imageFile = [documentsDirectory stringByAppendingPathComponent:name_png]; [UIImagePNGRepresentation(self.theImageView.image) writeToFile:imageFile

takepicture() vs UIGetScreenImage()

北战南征 提交于 2019-11-28 04:14:29
问题 I'm trying to build a QRCodeReader for a project our research group is working on for the iPhone. After much research I found the program called QuickMark . This program scans automatically for QRCodes. What it appears to do is load the UIImagePicker and read off data from the camera. I suspect it is using UIGetScreenImage and taking a screenshot from the camera and decoding it. Now I tried using the new takepicture() method from the 3.1 iPhone API but that seems not to be able to do what the

How to create a custom UIImagePickerController with full-screen images ios

本秂侑毒 提交于 2019-11-28 04:02:31
问题 I have a simple UIImagePickerController which will use the camera to take a picture, but there are a couple things I would like it to do: Have a custom camera UI Take a full-screen instead of 480x640 (if on 4inch phone) Here is my code for showing the UIImagePickerController: - (IBAction)pick:(id)sender { NSLog(@"abc"); picker = [[UIImagePickerController alloc] init]; if ([UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera]) { [picker setSourceType

How to get the custom overlay for UIImagePicker camera to be full screen in iOS 7?

為{幸葍}努か 提交于 2019-11-28 04:01:19
I am interested in using a custom overlay for the UIImagePickerController for camera controls that take the entire screen, very similar to what the default Camera app does when switched to the video function. I have referenced several questions here on SO on this topic, particularly this one , as well as the Apple example on how to use a custom overlay for the UIImagePickerController, but none of them have been able to produce a successful, full-screen result with iOS 7. So far, this is what the camera UI looks like with the custom overlay (without any buttons): Note that there is a black bar

UIImagePickerController camera view rotating strangely on iOS 8 (pictures)

纵饮孤独 提交于 2019-11-28 03:40:21
I have a very simple application: - All orientations are permitted with only a button on a screen - The button show a UIImagePickerController (to take a photo) - Build with Xcode 5 and SDK 7 On iOS 8 , the camera of the UIImagePickerController is appearing correctly whether I am in landscape or in portrait, but when I rotate the device, I got the camera view rotated by 90 degrees, here's a an example: I have my app in portrait I push the button that shows me the UIImagePickerController I am in the camera view and I go to landscape mode, here is what I get: The view is in landscape but the