25
I had the same problem. Say you want to present a view controller 2 from view controller 1. In the first view controller use
[self presentModalViewController: controller animated: NO]];
In the second view controller, in viewWillAppear: method add the code
CATransition *animation = [CATransition animation];
[animation setDelegate:self];
[animation setType:kCATransitionPush];
[animation setSubtype:kCATransitionFromRight];
[animation setDuration:0.40];
[animation setTimingFunction:
[CAMediaTimingFunction functionWithName:
kCAMediaTimingFunctionEaseInEaseOut]];
[self.view.layer addAnimation:animation forKey:kCATransition];
It will work fine. If black screen comes again, if you are using navigation controller, replace
[self.view.layer addAnimation:animation forKey:kCATransition];
with
[self.navigationController.view.layer addAnimation:animation forKey:kCATransition];