1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-03 01:06:44 +02:00

Implement simplistic VAD

This commit is contained in:
zugz (tox)
2020-05-07 00:00:00 +00:00
parent ddcf224db2
commit 7dead5ec96
18 changed files with 316 additions and 159 deletions

View File

@ -1440,20 +1440,10 @@ int main(int argc, char **argv)
prompt_init_statusbar(prompt, m, !datafile_exists);
load_conferences(m);
/* thread for ncurses stuff */
if (pthread_mutex_init(&Winthread.lock, NULL) != 0) {
exit_toxic_err("failed in main", FATALERR_MUTEX_INIT);
}
if (pthread_create(&Winthread.tid, NULL, thread_winref, (void *) m) != 0) {
exit_toxic_err("failed in main", FATALERR_THREAD_CREATE);
}
/* thread for message queue */
if (pthread_create(&cqueue_thread.tid, NULL, thread_cqueue, (void *) m) != 0) {
exit_toxic_err("failed in main", FATALERR_THREAD_CREATE);
}
#ifdef AUDIO
av = init_audio(prompt, m);
@ -1479,6 +1469,16 @@ int main(int argc, char **argv)
#endif /* AUDIO */
/* thread for ncurses stuff */
if (pthread_create(&Winthread.tid, NULL, thread_winref, (void *) m) != 0) {
exit_toxic_err("failed in main", FATALERR_THREAD_CREATE);
}
/* thread for message queue */
if (pthread_create(&cqueue_thread.tid, NULL, thread_cqueue, (void *) m) != 0) {
exit_toxic_err("failed in main", FATALERR_THREAD_CREATE);
}
#ifdef PYTHON
init_python(m);