- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
是否可以在 system("");
函数中使用 espeak
,例如 system("aplay 1.wav")
?
我喜欢在 Ubuntu 操作系统内的 C/C++ 代码中使用 espeak。
最佳答案
你不使用espeak
“像aplay
”,你在同一个命令中一起使用它们。
我相信您可以通过这种方式使用espeak
,但您使用的语法不正确。
您没有指定如何使用 espeak
,但这里有几个选项。
阅读引用的单词: system("espeak --stdout '要说的话' | aplay")
从文本文档中读取: system("espeak --stdout -t mydocument.txt | aplay")
在您帖子的评论中,您说您想使用命令system(“espeak answer”)
。假设 answer
是一个字符串变量,您可以尝试以下操作:
#include <string>
string answer, command;
command = "espeak --stdout '" + answer + "' | aplay";
system(command.c_str);
关于c++ - 是否可以在系统 "espeak"中使用 ("");功能?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50197069/
我第一次尝试在下面的代码中使用谷歌默认的TTS引擎,但是我发现,不支持波斯语! 因此,我在手机上下载并安装了 espeak RedZoc TTS 引擎,并将默认的 TTS 语言更改为波斯语。当我在手机
我正在尝试使用 espeak 实现一些功能,但缺少一些参数(我不知道)并在 Linux 上处理代码块下一个代码运行良好并读取阿拉伯文本 `#include #include #incl
我正在使用一个现有程序,该程序从套接字读取 xml,将文本转换为 wav 文件,然后通过音频输出设备播放。 我想将其剥离,以便它直接播放文本到音频。 现在我很难弄清楚我是否有正确的代码并理解它是否真的
我想知道是否有一种方法可以像在命令行中那样访问 espeak: laptop:~$espeak say this line first say this line second ... 现在,我在 p
是否可以控制 eSpeak 文本到语音的速度?如果可能的话 - 怎么做? 最佳答案 您可以使用 -s 指定每分钟的字数。选项,默认为 160 wpm。 espeak "hello world" -s
我一直在尝试使用 espeak 为 cmusphinx 创建一个字素到音素字典,但是当我从菜单中选择编译并选择编译字典时,它说编译成功,但我在任何地方都找不到 .dic 文件。 请告知在哪里可以找到我
我的应用程序中有这段文本到语音的代码。 public void onInit(int status) { // TODO Auto-generated method stub if
我正在使用 espeak来自 C++ 的 API 从我的嵌入式应用程序中进行一些简单的文本到语音合成。目前,我已经从关于如何开始的基本示例中复制了这一行: espeak_SetVoiceByName(
是否可以在 system(""); 函数中使用 espeak,例如 system("aplay 1.wav") ? 我喜欢在 Ubuntu 操作系统内的 C/C++ 代码中使用 espeak。 最佳答
我想在 windows7 中使用 espeak( http://espeak.sourceforge.net ) 和 python2.7.0-32 位。 另外,我还想保存espeak生成的音频文件。
我想将一个字符串传递给 espeak-ng,它通过声音读取我的字符串! 我搜索并找到了这个程序并做了一点修改以将其从意大利语更改为英语(在注释行下),但没有用: #include #include
这可能是个愚蠢的问题。 Firefox 相当严格,因为众所周知,Internet Explorer 可以毫无问题地激活病毒。但是对于我的英语课,我需要没有命令屏幕的 eSpeak。该程序在本地运行,但
我正在使用 espeak 库进行文本到语音的转换。我能够从字符串生成动态声音来执行此操作。 os.system('espeak "hello"') 这行得通。但我需要的是从字符串中生成声音。这是我做的
我正在创建一个基于 ruby 的应用程序,我希望它能读出一些文本。到目前为止,我正在使用 espeak: fork{exec ("espeak 'New file located #{timelo
我需要帮助。我使用 Raspberry pi 构建了一个机器人,然后用相机和扬声器对其进行了扩展。我安装了一个 lighthttpd 服务器,我可以使用一个简单的网站来控制它。 工作正常,网络服务器显
我在网上找到这段代码: #include #include #include espeak_POSITION_TYPE position_type; espeak_AUDIO_OUTPUT ou
问题:我正在尝试使用 espeak 文本转语音引擎。所以我让它在 linux 上运行得很好(下面的代码)。现在我也想将这个基本程序移植到 Windows,但这几乎是不可能的... 部分问题是 Wind
我在终端中从 Linux 运行 espeak,它工作得很好。我的问题是我想从 php(在 xampp 中)运行 espeak。 但是那是行不通的。并且没有发出任何声音 在 windows 中,当 p
这是我的代码。我想从用户那里得到 5 个字符串,当用户插入它时,espeak 会读取它们中的每一个。但是我收到了 segmentation fault(core dumped) 消息。 #includ
如何在声卡每次采集一个数字时听到口头的 DTMD 数字? 目标是 radio 控制我的电脑和接口(interface)事件,通过手持收发器调用 dtmf 音调。 我用 multimon 听 DTMF
我是一名优秀的程序员,十分优秀!