3 |
|
* |
4 |
|
* Adapted from Frodo's Solaris sound routines by Marc Chabanas |
5 |
|
* |
6 |
< |
* Basilisk II (C) 1997-2002 Christian Bauer |
6 |
> |
* Basilisk II (C) 1997-2004 Christian Bauer |
7 |
|
* |
8 |
|
* This program is free software; you can redistribute it and/or modify |
9 |
|
* it under the terms of the GNU General Public License as published by |
115 |
|
sound_buffer_size = (AudioStatus.sample_size>>3) * AudioStatus.channels * audio_frames_per_block; |
116 |
|
|
117 |
|
// Start audio thread |
118 |
< |
pthread_attr_init(&stream_thread_attr); |
119 |
< |
#if defined(_POSIX_THREAD_PRIORITY_SCHEDULING) |
120 |
< |
pthread_attr_setinheritsched(&stream_thread_attr, PTHREAD_EXPLICIT_SCHED); |
121 |
< |
pthread_attr_setschedpolicy(&stream_thread_attr, SCHED_FIFO); |
122 |
< |
struct sched_param fifo_param; |
123 |
< |
fifo_param.sched_priority = (sched_get_priority_min(SCHED_FIFO) + sched_get_priority_max(SCHED_FIFO)) / 2; |
124 |
< |
pthread_attr_setschedparam(&stream_thread_attr, &fifo_param); |
125 |
< |
#endif |
118 |
> |
Set_pthread_attr(&stream_thread_attr, 0); |
119 |
|
stream_thread_active = (pthread_create(&stream_thread, &stream_thread_attr, stream_func, NULL) == 0); |
120 |
|
|
121 |
|
// Everything OK |