AVSpeechSynthesizer 语音合成器
来源:互联网 发布:田岛绣花软件9.0 编辑:程序博客网 时间:2024/05/22 05:25
NSArray *speechStrings =
@[@"Hello AV Foundation. How are you?",
@"I'm well! Thanks for asking.",
@"Are you excited about the book?",
@"Very! I have always felt so misunderstood.",
@"What's your favorite feature?",
@"Oh, they're all my babies. I couldn't possibly choose.",
@"It was great to speak with you!",
@"The pleasure was all mine! Have fun!"];
AVSpeechSynthesizer *synthesizer = [[AVSpeechSynthesizeralloc] init];
for (NSUInteger i =0; i < speechStrings.count; i++) {
AVSpeechUtterance *utterance = [[AVSpeechUtterancealloc] initWithString:speechStrings[i]];utterance.voice = [AVSpeechSynthesisVoicevoiceWithLanguage:@"en-US"];//设置使用什么语言播放
utterance.rate =1.0f; //设置语音内容的速度(0-1)
utterance.pitchMultiplier =0.8f; //改变合成声音的音调
utterance.postUtteranceDelay =1; //目的是让语音合成器播放下一语句前又短暂的暂停
[synthesizerspeakUtterance:utterance];
}
- iOS7- AVSpeechSynthesizer(语音合成器)
- AVSpeechSynthesizer 语音合成器
- iOS- AVSpeechSynthesizer——iOS7语音合成器
- iOS- AVSpeechSynthesizer——iOS7语音合成器
- iOS- AVSpeechSynthesizer——iOS7语音合成器
- 文字转语音AVSpeechSynthesizer
- iOS-AVSpeechSynthesizer语音合成
- AVFoundation之语音合成器
- iOS7 文本转语音 AVSpeechSynthesizer
- iOS7 文本转语音 AVSpeechSynthesizer
- iOS用AVSpeechSynthesizer合成语音
- iOS 语音合成 AVSpeechSynthesizer详解
- ios 文本转语音 播报 AVSpeechSynthesizer
- iOS AVSpeechSynthesizer进行文字转语音
- IOS开发笔记之文字转语音AVSpeechSynthesizer用法
- AVSpeechSynthesizer文字转语音播放(需真机)详解
- iOS 语音播放文字内容--制作简易听书软件(AVSpeechSynthesizer)
- 使用AVSpeechSynthesizer添加"文本转语音"的功能
- unity5中AssetBundle相关
- ViewPager实现一个页面多个Item的显示
- swift-UI-01
- swift如何判断debug模式和release模式
- JAVA命名规则
- AVSpeechSynthesizer 语音合成器
- C#反射机制总结
- AMQP协议
- UVA227
- 自适应响应式网页设计(Responsive Web Design)
- iOS 加载显示 Word PDF Excel
- 怎样在Ubuntu15.04上安装fish shell
- iOS CAGradientLayer 详解
- SVN管理工具Cornerstone之:创建分支、提交合并