mirror of
https://github.com/rhasspy/espeak-ng.git
synced 2026-10-31 05:35:35 +00:00
bugfix: force bitrate to 16 for SSML <audio>.
Espeak-ng uses bitrate 16 internally. If the input inside <audio> has a different bitrate the audio will not play correctly unless converted to 16 bits. Closes #885.
This commit is contained in:
@@ -349,7 +349,7 @@ static espeak_ng_STATUS LoadSoundFile(const char *fname, int index, espeak_ng_ER
|
||||
strcpy(fname_temp, tmpnam(NULL));
|
||||
#endif
|
||||
|
||||
sprintf(command, "sox \"%s\" -r %d -c1 -t wav %s\n", fname, samplerate, fname_temp);
|
||||
sprintf(command, "sox \"%s\" -r %d -c1 -b 16 -t wav %s\n", fname, samplerate, fname_temp);
|
||||
if (system(command) == 0)
|
||||
fname = fname_temp;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user