From 3db4f81573d89f6ebefb5ec119c7d66affc1a4a0 Mon Sep 17 00:00:00 2001 From: yum Date: Thu, 31 Aug 2023 17:11:11 -0700 Subject: Bugfixes and tweaks * Temporarily restore normal process priority. Working on adding a UI option to set STT prio. * Give audio indicator phonemes a 1/3 chance to do nothing. Makes result sound a little better imo. * Quiet down steamVR thread when steamVR isn't running * Fix use of `button_id` and `hand_id` in steamvr.py * Increase amount of silence allowed before transcript from 1 to 5 seconds. You want enough buffer to allow for a few full transcripts, else you risk spuriously dropping audio. * Enable background loading in audio metadata (required by vrc sdk) --- GUI/GUI/GUI/PythonWrapper.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'GUI') diff --git a/GUI/GUI/GUI/PythonWrapper.cpp b/GUI/GUI/GUI/PythonWrapper.cpp index c4367e8..71df5c5 100644 --- a/GUI/GUI/GUI/PythonWrapper.cpp +++ b/GUI/GUI/GUI/PythonWrapper.cpp @@ -282,6 +282,8 @@ bool PythonWrapper::InvokeCommandWithArgs(const std::string& cmd, }); // Set spawned process priority to low, to avoid lagging things like OBS. + // TODO(yum) make a toggle for this. +#if 0 if (!SetPriorityClass(pi.hProcess, BELOW_NORMAL_PRIORITY_CLASS)) { std::ostringstream err_oss; err_oss << "Error while executing python command \"" << cmd_oss.str() @@ -289,6 +291,7 @@ bool PythonWrapper::InvokeCommandWithArgs(const std::string& cmd, out_cb("", err_oss.str()); return false; } +#endif // While the process is running, drain output and send input every 10 ms. DWORD timeout_ms = 10; -- cgit v1.2.3