时间:2017-08-01作者:xp系统之家 来源:http://www.37m.cn
图1:Cortana
图2:来至微软小娜的问候
w7装机版怎么使用powershelll让Cortana朗读小说?
1、把下面的代码复制为.ps1文件保存好,打开powershell(管理员),把执行.ps1文件。当然也可以复制之后即可执行命令,都是一样的效果。
= "HKLM:/soFTwARE/Microsoft/speech_oneCore/Voices/Tokens/MsTTs_V110_zhCn_HongyuM"= "HKLM:/soFTwARE/Microsoft/speech_oneCore/Voices/Tokens/MsTTs_V110_zhCn_HongyuM/Attributes"= "HKLM:/soFTwARE/Microsoft/speech/Voices/Tokens/MsTTs_V110_zhCn_HongyuM"= "HKLM:/soFTwARE/Microsoft/speech/Voices/Tokens/MsTTs_V110_zhCn_HongyuM/Attributes"new-item -path ,,,new-itemproperty -path , -name "(default)" -propertyType string -Value "Microsoft Hongyu Mobile - Chinese (simplified, pRC)"new-itemproperty -path , -name Langdatapath -propertyType string -Value "%windir%//speech_oneCore//Engines//TTs//zh-Cn//MsTTsLoczhCn.dat"new-itemproperty -path , -name Langupdatedatadirectory -propertyType string -Value "%systemdrive%//data//shareddata//speech_oneCore//Engines//TTs//zh-Cn"new-itemproperty -path , -name Voicepath -propertyType string -Value "%windir%//speech_oneCore//Engines//TTs//zh-Cn//M2052Hongyu"new-itemproperty -path , -name Voiceupdatedatadirectory -propertyType string -Value "%systemdrive%//data//shareddata//speech_oneCore//Engines//TTs//zh-Cn"new-itemproperty -path , -name 804 -propertyType string -Value "Microsoft Hongyu Mobile - Chinese (simplified, pRC)"new-itemproperty -path , -name CLsid -propertyType string -Value "{179F3d56-1B0B-42B2-A962-59B7EF59FE1B}"new-itemproperty -path , -name Version -propertyType string -Value "11.0"new-itemproperty -path , -name Language -propertyType string -Value "804"new-itemproperty -path , -name Gender -propertyType string -Value "Female"new-itemproperty -path , -name Age -propertyType string -Value "Adult"new-itemproperty -path , -name dataVersion -propertyType string -Value "11.0.2013.1022"new-itemproperty -path , -name sharedpronunciation -propertyType string -Value ""new-itemproperty -path , -name name -propertyType string -Value "Microsoft Hongyu Mobile"new-itemproperty -path , -name Vendor -propertyType string -Value "Microsoft"new-itemproperty -path , -name personalAssistant -propertyType string -Value "1"
2、接下来打开“控制面板”,找到“语音识别”,点击左侧窗口中的“文本到语音转换”,在“语音选择”框中选择“Microsoft Hongyu Mobile - Chinese (simplified, pRC)”,然后单击确定按钮,您就可以让微软小娜为您阅读文本了。阅读文本内容可以使用带有文本阅读功能的文本编辑器,或者使用专门的小说阅读器,大家自己选一个自己喜爱的就行了。
图3:选择小娜的语音
3、下面贴一段用powershell阅读小说的代码,同样保存为.ps1文件,然后在.ps1文件上右键,选择“使用“使用powershell运行”,之后把txt小说拖到powershell窗口中,回车,小娜就会自动为您朗读小说了,再次回车就会退出朗读!
= Read-Host -prompt "把小说拖到此处并回车开始朗读"= new-object -Comobject sApi.spVoice.speak(,5)Read-Host -prompt "回车退出朗读"
图4:使用小娜朗读小说
以上就是让Cortana为你们朗读小说的操作办法,喜爱阅读的朋友,如果看书看累了,不如让小娜为你朗读哦!
本站发布的ghost系统与电脑软件仅为个人学习测试使用,不得用于任何商业用途,否则后果自负!