This commit is contained in:
2021-04-06 02:16:09 +02:00
parent b444508fb8
commit 110b78c762
11 changed files with 88 additions and 22 deletions

11
tts/espeak/index.js Normal file
View File

@@ -0,0 +1,11 @@
const BaseEngine=require('../BaseEngine')
const {spawn} = require('child_process')
module.exports=class extends BaseEngine {
constructor() {
super('ESpeak','wav')
}
async getSpeechFile(text, filepath, voice='en', params={}) {
await spawn('espeak', ['-v', voice, '-w',filepath, text]);
}
}