Showing UIImagePickerController in portrait

I ran into this issue in my app and was able to reproduce it in a sample app. This is an iOS 8 only app that supports all orientations and allows you to take a picture to upload. If I invoke the camera in portrait mode it's all good, everything works fine. If the app is in landscape and I invoke the camera, it shows up rather very weird-looking, pointed to the wrong orientation, missing the cancel button and taking only half the screen. I'm using UIImagePickerController. As far as I can tell, Apple's Contacts app is using that too(at least from the visual look) and seems to work fine.

Here's how I invoke the camera:


UIImagePickerController *imagePickerController = [[UIImagePickerController alloc] init];
imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera;
imagePickerController.delegate = self;
imagePickerController.modalPresentationStyle = UIModalPresentationFullScreen;
[self presentViewController:imagePickerController animated:YES completion:nil];
return;



self in this case is a plain vanilla UIViewController straight out of the Apple template for Single-View application, and the code is in a block that handles the response when getting permission to use the camera.

What gives? Seems like this should be possible, but the Internet is failing me. Everywhere I looked has questions about showing UIImagePickerController in landscape, but I don't care about that. I don't mind it showing in portrait when I'm in landscape as long as it actually shows up correctly!

Cross-posted to stackoverflow.

Showing UIImagePickerController in portrait
 
 
Q