UIImageView *imgView = [[UIImageView alloc] initWithFrame:CGRectMake(dragger.frame.origin.x, dragger.frame.origin.y,dragger.frame.size.width, dragger.frame.size.height)] ;
imgView.image = dragger.image;
overlayView = [[UIView alloc] initWithFrame:CGRectMake(dragger.frame.origin.x,dragger.frame.origin.y,dragger.frame.size.width, dragger.frame.size.height)];
[overlayView addSubview:imgView];
//open the camera
self.picker = [[UIImagePickerController alloc] init];
self.picker.delegate = self;
self.picker.sourceType = UIImagePickerControllerSourceTypeCamera;
self.picker.cameraOverlayView=overlayView;
[self.navigationController presentModalViewController:self.picker animated:YES];
在纵向模式下可以正常工作,但叠加图像在横向模式下不会改变。iPhone相机中的问题overelay图像方向
我该如何做到这一点,因为我需要帮助吗?
我也面临着同样的问题。这个链接帮助我解决了这个问题。 http://stackoverflow.com/questions/5427656/ios-uiimagepickercontroller-result-image-orientation-after-upload –