Cognitive Services 簡介
PlayFab Party Cognitive Services 介面包含可設定及使用 PlayFab Party 所提供之協助工具功能的函式。 這些功能包括:- 即時文字聊天翻譯
- 即時語音聊天轉譯
- 即時語音聊天轉譯翻譯
- 文字轉語音合成
定價
核心 VOIP 和遊戲網路功能以外的 Cognitive Services 和其他服務可能會有相關費用。如需詳細資料,請造訪 PlayFab Party 的計費頁面,或連絡您的 Microsoft 代表。使用 Cognitive Services 介面
若要在遊戲中使用 Cognitive Services 介面,請將下列程式碼區塊新增至遊戲的 Build.cs 檔案。SetTextChatTranslationOptions
SetTextChatTranslationOptions 可開啟或關閉聊天翻譯。SetVoiceChatTranscriptionOptions
啟用及設定語音轉譯時需要 SetVoiceChatTranscriptionOptions。- bTranscribeSelf - 會產生本機聊天控制項的轉譯,並提供給同一個本機聊天控制項
- bTranscribeOtherChatControlsWithMatchingLanguages - 會產生與本機聊天控制項語言相同之其他聊天控制項的轉譯,並提供給本機聊天控制項
- bTranscribeOtherChatControlsWithNonMatchingLanguages - 會產生語言與本機聊天控制項語言不同之其他聊天控制項的轉譯,並提供給本機聊天控制項
- bTranslateToLocalLanguage - 轉譯會翻譯為本機聊天控制項的語言
SetTextToSpeechOptions
啟用及設定文字轉語音時需要 SetTextToSpeechOptions。- ETextToSpeechType::Narration - 將音訊轉譯至本機聊天控制項的音訊輸出
- ETextToSpeechType::VoiceChat - 將音訊轉譯至本機聊天控制項設定為傳送音訊的聊天控制項
