Add ability for directory to use mod_flite or mod_cepstral (#1644)
This commit is contained in:
parent
2cbc5f34f3
commit
cfc20ca9bf
|
|
@ -54,6 +54,16 @@
|
|||
storage_type = settings['voicemail']['storage_type']['text'];
|
||||
end
|
||||
end
|
||||
if (settings['voicemail']['speak_mod'] ~= nil) then
|
||||
if (settings['voicemail']['speak_mod']['text'] ~= nil) then
|
||||
speak_mod = settings['voicemail']['speak_mod']['text'];
|
||||
end
|
||||
end
|
||||
if (settings['voicemail']['speak_voice'] ~= nil) then
|
||||
if (settings['voicemail']['speak_voice']['text'] ~= nil) then
|
||||
speak_voice = settings['voicemail']['speak_voice']['text'];
|
||||
end
|
||||
end
|
||||
if (settings['voicemail']['storage_path'] ~= nil) then
|
||||
if (settings['voicemail']['storage_path']['text'] ~= nil) then
|
||||
storage_path = settings['voicemail']['storage_path']['text'];
|
||||
|
|
@ -239,10 +249,18 @@
|
|||
session:streamFile(file_location);
|
||||
else
|
||||
--announce the first and last names
|
||||
session:execute("say", "en name_spelled iterated "..row.first_name);
|
||||
if (speak_mod ~= nil and speak_voice ~= nil) then
|
||||
session:execute("speak",speak_mod.."|"..speak_voice.."|"..row.first_name);
|
||||
else
|
||||
session:execute("say", "en name_spelled iterated "..row.first_name);
|
||||
end
|
||||
--session:execute("sleep", "500");
|
||||
if (row.last_name ~= nil) then
|
||||
session:execute("say", "en name_spelled iterated "..row.last_name);
|
||||
if (speak_mod ~= nil and speak_voice ~= nil) then
|
||||
session:execute("speak",speak_mod.."|"..speak_voice.."|"..row.last_name);
|
||||
else
|
||||
session:execute("say", "en name_spelled iterated "..row.last_name);
|
||||
end
|
||||
end
|
||||
end
|
||||
end);
|
||||
|
|
@ -259,10 +277,18 @@
|
|||
session:streamFile(voicemail_dir.."/"..row.extension.."/recorded_name.wav");
|
||||
else
|
||||
--announce the first and last names
|
||||
session:execute("say", "en name_spelled iterated "..row.first_name);
|
||||
if (speak_mod ~= nil and speak_voice ~= nil) then
|
||||
session:execute("speak",speak_mod.."|"..speak_voice.."|"..row.first_name);
|
||||
else
|
||||
session:execute("say", "en name_spelled iterated "..row.first_name);
|
||||
end
|
||||
if (row.last_name ~= nil) then
|
||||
--session:execute("sleep", "500");
|
||||
session:execute("say", "en name_spelled iterated "..row.last_name);
|
||||
if (speak_mod ~= nil and speak_voice ~= nil) then
|
||||
session:execute("speak",speak_mod.."|"..speak_voice.."|"..row.last_name);
|
||||
else
|
||||
session:execute("say", "en name_spelled iterated "..row.last_name);
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue