Я пытаюсь программно создать изображение из текущего кадра видео MPMoviePlayerController.Я использую renderInContext, вызываемый на плеере view.layer, однако созданное изображение полностью черное с элементами управления видеопроигрывателя, но я ожидаю увидеть текущий кадр видео
Мой код (http://pastie.org/1020066)
UIGraphicsBeginImageContext(moviePlayer.view.bounds.size);
[moviePlayer.view.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
// I also tried this code (same results)
// moviePlayer is a subview of videoView (UIView object)
UIGraphicsBeginImageContext(videoView.bounds.size);
[videoView.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();