시도 뭔가 :
- (void) getFullScreenScreenShot
{
AppDelegate* appDelegate = (AppDelegate*)[[UIApplication sharedApplication] delegate];
UIView* superView = appDelegate.viewController.view;
CGRect fullScreenFrame = superView.frame;
UIGraphicsBeginImageContextWithOptions(fullScreenFrame.size, YES, 0.0f);
CGContextTranslateCTM(UIGraphicsGetCurrentContext(), 0.0f, 0.0f);
[superView.layer renderInContext: UIGraphicsGetCurrentContext()];
UIImageView* screenShot = [[UIImageView alloc] initWithImage: UIGraphicsGetImageFromCurrentImageContext()];
UIGraphicsEndImageContext();
NSData* imageData = UIImageJPEGRepresentation(screenShot.image, 1.0);
NSString* previewFileNamePath = [[CPFileManager documentsPath] stringByAppendingString: @"image.jpg"];
if ([imageData writeToFile: previewFileNamePath
atomically: NO])
{
NSLog(@"See filename:%@", previewFileNamePath);
}
else
{
NSLog(@"Error: %@", previewFileNamePath);
}
}
'caputureView' 무엇입니까? 자신이 옳은지 확인하십시오 - 디버그하십시오. – Wain
명확하게 입력하고 입력 및 회전식보기 데이터에 사용 무엇 – Mahe
@DO Sunhour : 당신은 화면의 하드 코딩 된 크기를 주려고 했나요? 창 캡처를 시도하십시오. – Nilesh