【问题标题】:Is the following screenshot code acceptable for use in an App Store app?以下屏幕截图代码是否可以在 App Store 应用程序中使用?
【发布时间】:2012-06-25 03:38:16
【问题描述】:

我正在使用此代码在 iOS 5.0 应用上的应用中截屏:

UIGraphicsBeginImageContext(self.view.bounds.size);
[self.view.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
UIImageWriteToSavedPhotosAlbum(viewImage, nil, nil, nil);           

这是为将提交到 App Store 的应用程序截屏的可接受方式吗?我听说其他应用程序因截屏而被拒绝,所以我想确保这是正确的。

【问题讨论】:

  • 只是截图并不会让他们拒绝该应用程序。它是您放置它的框架。 [这里][1] 有一篇精彩的文章。 [1]:iostipsntricks.wordpress.com/2011/05/12/…
  • 我过去用这段代码截图,苹果没有拒绝该应用。

标签: ios screenshot


【解决方案1】:

该代码可以用于截屏。

您听说过应用被拒绝是因为有(或曾经有)一个函数 UIGetScreenImage 会返回屏幕截图。然而,苹果后来决定停止允许应用使用该功能,并开始拒绝使用该功能的应用。

Announcement allowing use of UIGetScreenImage

Announcement prohibiting use of UIGetScreenImage

【讨论】:

    猜你喜欢
    • 2013-10-25
    • 1970-01-01
    • 2018-04-21
    • 1970-01-01
    • 2017-03-27
    • 2014-04-13
    • 2018-12-13
    • 2014-09-15
    • 2019-04-21
    相关资源
    最近更新 更多