summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2024-07-20 11:13:27 -0400
committerSolomon Peachy <pizza@shaftnet.org>2024-07-20 11:18:22 -0400
commite0b34a5c4d5d214b03decbd6420d4c0a38700f49 (patch)
treeea0db5645604961f6dbe9ad9932d90444f3dc25c
parent6bfcba44226005a5c361594d855ee8d5d958af38 (diff)
downloadrockbox-e0b34a5c4d.tar.gz
rockbox-e0b34a5c4d.zip
FS#13449: Generate standalone voice clips in rbutil
VOICE_INVALID_VOICE_FILE and VOICE_LANG_NAME need to be discretely saved as "InvalidVoice_<langname>.talk" and "<langname>.lng.talk" under the target .rockbox/langs directory This mirrors what the standalone voice.pl and buildzip.pl do. Change-Id: I70fda4ffe85b5bccc164ebcbb484eedf034f143b
-rw-r--r--utils/rbutilqt/base/voicefile.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/utils/rbutilqt/base/voicefile.cpp b/utils/rbutilqt/base/voicefile.cpp
index dbdd56e53e..267af18010 100644
--- a/utils/rbutilqt/base/voicefile.cpp
+++ b/utils/rbutilqt/base/voicefile.cpp
@@ -247,8 +247,7 @@ void VoiceFileCreator::create(void)
TalkGenerator::TalkEntry entry;
entry.toSpeak = voice;
entry.wavfilename = m_path + "/" + id + ".wav";
- //voicefont wants them with .mp3 extension
- entry.talkfilename = m_path + "/" + id + ".mp3";
+ entry.talkfilename = m_path + "/" + id + ".enc";
entry.voiced = false;
entry.encoded = false;
if(id == "VOICE_PAUSE")
@@ -324,6 +323,10 @@ void VoiceFileCreator::create(void)
voicefont(ids2,m_targetid,m_path.toLocal8Bit().data(), output, m_voiceformat);
// ids2 and output are closed by voicefont().
+ // Copy these two over to the device
+ QFile::copy(m_path + "/VOICE_INVALID_VOICE_FILE.enc", m_mountpoint + "/.rockbox/langs/InvalidVoice_" + m_lang + ".talk");
+ QFile::copy(m_path + "/VOICE_LANG_NAME.enc", m_mountpoint + "/.rockbox/langs/" + m_lang + ".lng.talk");
+
//cleanup
cleanup();
@@ -359,4 +362,3 @@ void VoiceFileCreator::cleanup()
return;
}
-