ios - 为什么我在 iOS 设备测试中得到 "Building MacinTalk voice for asset: (null)"

标签 ios text-to-speech

我正在为设备上的文本到语音项目执行以下代码,但出现错误“为 Assets 构建 MacinTalk 语音:(空)” 请帮助我解决问题或提示问题所在。

 AVSpeechSynthesizer *synthesizer = [[AVSpeechSynthesizer alloc]init];
    AVSpeechUtterance *utterance = [AVSpeechUtterance speechUtteranceWithString:@"Tips For Silicon Valley From A Startup Accelerator In Gaza"];
    [utterance setRate:0.015f];
    utterance.voice = [AVSpeechSynthesisVoice voiceWithLanguage:@"en-GB"];
    [synthesizer speakUtterance:utterance];

最佳答案

如果它和我看到的一样,那么它真的不是错误 - 它是日志的输出和一个小麻烦,但可以忽略。引用“null”令人担忧,但 speechSynthesizer 仍在正常工作并正常说话,用户不会在真实设备上看到此消息。我从 iOS9 之后才看到这个,可能是在开发过程中他们忘记关闭的日志事件打开了。

关于ios - 为什么我在 iOS 设备测试中得到 "Building MacinTalk voice for asset: (null)",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32774480/

相关文章:

ios - 具有关联类型的 Swift 协议(protocol)中的弱属性要求

iOS 执行 pushViewController 并且不弹出

iphone - 核心数据关系困惑

javascript - 如何从 Speech Synthesis API 访问音频结果?

python - 为什么在目录中循环访问.wav文件时显示错误,但在不循环时工作正常?

ios 执行大数计算

android - 在 Android 上使用 TTS : Punctuation is read aloud

text-to-speech - 在 SSML 中为 TTS 使用 <prosody> 标签时出现不需要的停顿

python - 如何在 'gTTS' 中使用多语言输入单行?

ios - 再次点击当前 Tab Bar 时,如何在 UITableView 中滚动到顶部?