Commit 745c243b authored by Miller Puckette's avatar Miller Puckette
Browse files

remove printout

parent b4e98c29
......@@ -340,11 +340,11 @@ void sched_set_using_audio(int flag)
sched_referencerealtime = sys_getrealtime();
sched_referencelogicaltime = clock_getlogicaltime();
}
if (flag == SCHED_AUDIO_CALLBACK && sched_useaudio != SCHED_AUDIO_CALLBACK)
sys_quit = SYS_QUIT_RESTART;
if (flag != SCHED_AUDIO_CALLBACK && sched_useaudio == SCHED_AUDIO_CALLBACK)
post("sorry, can't turn off callbacks yet; restart Pd"); /* not right yet! */
if (flag == SCHED_AUDIO_CALLBACK && sched_useaudio != SCHED_AUDIO_CALLBACK)
sys_quit = SYS_QUIT_RESTART;
if (flag != SCHED_AUDIO_CALLBACK && sched_useaudio == SCHED_AUDIO_CALLBACK)
post("sorry, can't turn off callbacks yet; restart Pd"); /* not right yet! */
sys_time_per_dsp_tick = (TIMEUNITPERSEC) *
((double)sys_schedblocksize) / sys_dacsr;
}
......@@ -440,11 +440,11 @@ static void m_pollingscheduler( void)
if (!(idlecount & 31))
{
static double idletime;
if (sched_useaudio != SCHED_AUDIO_POLL)
{
bug("m_pollingscheduler\n");
return;
}
if (sched_useaudio != SCHED_AUDIO_POLL)
{
bug("m_pollingscheduler\n");
return;
}
/* on 32nd idle, start a clock watch; every
32 ensuing idles, check it */
if (idlecount == 32)
......@@ -539,16 +539,15 @@ int m_mainloop(void)
{
while (sys_quit != SYS_QUIT_QUIT)
{
post("sched %d", sched_useaudio);
if (sched_useaudio == SCHED_AUDIO_CALLBACK)
m_callbackscheduler();
else m_pollingscheduler();
if (sys_quit == SYS_QUIT_RESTART)
{
sys_quit = 0;
if (sys_quit == SYS_QUIT_RESTART)
{
sys_quit = 0;
sys_close_audio();
sys_reopen_audio();
}
}
}
return (0);
}
......
......@@ -376,7 +376,6 @@ void sys_reopen_audio( void)
int rate, advance, callback, outcome = 0;
sys_get_audio_params(&naudioindev, audioindev, chindev,
&naudiooutdev, audiooutdev, choutdev, &rate, &advance, &callback);
post("x 1");
if (!naudioindev && !naudiooutdev)
{
sched_set_using_audio(SCHED_AUDIO_NONE);
......@@ -386,7 +385,6 @@ void sys_reopen_audio( void)
if (sys_audioapi == API_PORTAUDIO)
{
int blksize = (sys_blocksize ? sys_blocksize : 64);
post("x 2 %d", callback);
outcome = pa_open_audio((naudioindev > 0 ? chindev[0] : 0),
(naudiooutdev > 0 ? choutdev[0] : 0), rate, sys_soundin,
sys_soundout, blksize, sys_advance_samples/blksize,
......@@ -424,7 +422,6 @@ void sys_reopen_audio( void)
else
#endif
post("unknown audio API specified");
post("x 3 %d %d", callback, outcome);
if (outcome) /* failed */
{
audio_state = 0;
......@@ -733,13 +730,13 @@ void glob_audio_dialog(t_pd *dummy, t_symbol *s, int argc, t_atom *argv)
}
}
if (audio_callback == newcallback)
sys_close_audio();
if (audio_callback == newcallback)
sys_close_audio();
sys_set_audio_settings(nindev, newaudioindev, nindev, newaudioinchan,
noutdev, newaudiooutdev, noutdev, newaudiooutchan,
newrate, newadvance, (newcallback >= 0 ? newcallback : 0));
if (audio_callback == newcallback)
sys_reopen_audio();
if (audio_callback == newcallback)
sys_reopen_audio();
}
void sys_listdevs(void )
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment