I am having trouble with UIView which is feeding by an image from Camera Roll.
When I pick a picture which was taken in the portrait mode the view always stretch the picture too high, but when I rotate my device the picture is stretched fine.
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info {
if(info){
{
[artView removeFromSuperview];
artView = nil;
artView = [[UIImageView alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]];
artView.image = [info objectForKey:UIImagePickerControllerOriginalImage];
artView.autoresizingMask = UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth;
artView.contentMode = UIViewContentModeScaleAspectFill;
[self.contentView addSubview:artView];
Any help is appreciated.