Basic mixer for OSX -- multi demod streams working

RtAudio can’t open multiple streams, so now opening a new device will
start a static audio thread and all other threads will attach/detach
their input queues there.
This commit is contained in:
Charles J. Cliffe
2014-12-18 20:11:25 -05:00
parent 493d9da8a7
commit b196fbfdea
11 changed files with 271 additions and 58 deletions
+6 -6
View File
@@ -89,12 +89,12 @@ int SDRThread::enumerate_rtl() {
}
void SDRThread::threadMain() {
//#ifdef __APPLE__
// pthread_t tID = pthread_self(); // ID of this thread
// int priority = sched_get_priority_min( SCHED_RR );
// sched_param prio = { priority }; // scheduling priority of thread
// pthread_setschedparam( tID, SCHED_RR, &prio );
//#endif
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max( SCHED_FIFO )-1;
sched_param prio = { priority }; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_FIFO, &prio);
#endif
std::cout << "SDR thread initializing.." << std::endl;