Libraryless. Click here for Pure Java version (4008L/28K).
1 | static File espeakToWAV(S text, S voice) {
|
2 | File wav = prepareCacheProgramFile("Computer Voices/eSpeak/" + uniqueFileNameUsingMD5_80_v2(appendIfNempty(voice, "|") + text) + ".wav");
|
3 | if (fileEmptyOrNotThere(wav)) |
4 | espeakToWAV(text, voice, wav); |
5 | ret wav; |
6 | } |
7 | |
8 | static File espeakToWAV(S text, S voice, File wav) {
|
9 | backtick("espeak "
|
10 | + "-w " + platformQuoteOpt(wav) |
11 | + (nempty(voice) ? "-v " + platformQuoteOpt(voice) : "") |
12 | + platformQuote(text)); |
13 | ret wav; |
14 | } |
Began life as a copy of #1024505
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
| Snippet ID: | #1026989 |
| Snippet name: | espeakToWAV [if on path] |
| Eternal ID of this version: | #1026989/1 |
| Text MD5: | bdee4759ecaa3972e4bd26940a1dcf60 |
| Transpilation MD5: | 6ef657b0044975073217c9f8c8974692 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2020-02-06 11:52:58 |
| Source code size: | 490 bytes / 14 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 541 / 661 |
| Referenced in: | [show references] |