美文网首页
文本转语音

文本转语音

作者: iamgaoshuai | 来源:发表于2016-03-29 19:14 被阅读15次

    工程建好后首先把AVFoundation.framework 加入到工程

    AVSpeechSynthesizer *av = [[AVSpeechSynthesizer alloc]init];

    AVSpeechUtterance *utterance = [[AVSpeechUtterance alloc]initWithString:@"Hello qingjoin"]; //需要转换的文本

    [av speakUtterance:utterance];

    相关文章

      网友评论

          本文标题:文本转语音

          本文链接:https://www.haomeiwen.com/subject/sayslttx.html