我制作了一个应用程序,可以从用户那里获取图像和声音记录,并在回放声音片段并显示图像时执行屏幕记录。该产品是一个小型视频,可以共享(通过短信或电子邮件发送)。我已经进行了设置,因此一旦声音停止播放,屏幕录制就会自动停止。
func audioPlayerDidFinishPlaying(_ player: AVAudioPlayer, successfully flag: Bool) {
screenRecorder.stopRecording { (previewVC, error) in
self.doneButton.isEnabled = true
print("audio stopped playing")
print("stopRecording error is \(String(describing: error ?? nil))")
if error != nil {
self.displayAlert(title: "Sorry", message: "We couldn't make your clip. Disconnect your iPhone from any Bluetooth speakers and try again.\n\nIf this keeps happening, exit the app (double-press the home button and up-swipe the app page). Then re-open the app.")
}
if let previewVC = previewVC {
previewVC.previewControllerDelegate = self
self.present(previewVC, animated: true, completion: nil)
}
}
}
func previewControllerDidFinish(_ previewController: RPPreviewViewController) {
dismiss(animated: true, completion: nil)
}
当我尝试共享视频时出现问题。在将应用上传到应用商店之前,一切正常,如下所示:
但是在应用被接受并上传到应用商店后,每个共享视频都包含一个指向应用商店的链接,如下所示。我不要这个连结。我该如何摆脱呢?