gpt4 book ai didi

ios - WatchKit 项目无法识别 presentAudioRecordingControllerWithOutputURL

转载 作者:行者123 更新时间:2023-11-29 12:20:19 26 4
gpt4 key购买 nike

我有一个 WatchKit 的现有项目,随着新的 WatchOS 版本的发布,Apple 已经实现了一个名为 presentAudioRecordingControllerWithOutputURL 的方法来从 AppleWatch 录制音频。

当我调用这个方法时,我有两个编译错误。我想我必须添加或包含更多内容,但我不知道我必须在我的项目中更改什么。

enter image description here

错误:

/path/myProject WatchKit Extension/AWMessagesController.m:278:56: 'WKAudioRecordingPresetWideBandSpeech' is unavailable: not available on iOS

/path/myProject WatchKit Extension/AWMessagesController.m:277:11: 'presentAudioRecordingControllerWithOutputURL:preset:maximumDuration:actionTitle:completion:' is unavailable: not available on iOS

最佳答案

presentAudioRecordingControllerWithOutputURL 不能在 iOS 扩展中使用。您必须适本地迁移您的代码(例如,将文件复制到监视目标)。引用Apple's documentation .

关于ios - WatchKit 项目无法识别 presentAudioRecordingControllerWithOutputURL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30828303/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com