Changeset 1488:0dcc3be9917e in roaraudio
- Timestamp:
- 03/31/09 00:10:53 (15 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roard/loop.c
r982 r1488 29 29 int term = 0; 30 30 int streams; 31 #ifdef ROAR_HAVE_GETTIMEOFDAY 31 32 long int loopc = 0; 32 33 struct timeval try, ans; 33 34 float freq; 35 #endif 34 36 #ifdef MONITOR_LATENCY 35 37 long int ans_1last = 0, ans_2last = 0, ans_3last = 0; … … 43 45 g_pos = 0; 44 46 47 #ifdef ROAR_HAVE_GETTIMEOFDAY 45 48 if ( sysclocksync ) { 46 49 gettimeofday(&try, NULL); 47 50 } 51 #endif 48 52 49 53 while (alive) { 50 #if def MONITOR_LATENCY54 #if defined(MONITOR_LATENCY) && defined(ROAR_HAVE_GETTIMEOFDAY) 51 55 gettimeofday(&try, NULL); 52 56 #endif … … 96 100 g_pos = ROAR_MATH_OVERFLOW_ADD(g_pos, ROAR_OUTPUT_BUFFER_SAMPLES*g_sa->channels); 97 101 ROAR_DBG("main_loop(*): current pos: %u", g_pos); 98 #if def MONITOR_LATENCY102 #if defined(MONITOR_LATENCY) && defined(ROAR_HAVE_GETTIMEOFDAY) 99 103 gettimeofday(&ans, NULL); 100 104 … … 116 120 #endif 117 121 122 #ifdef ROAR_HAVE_GETTIMEOFDAY 118 123 if ( sysclocksync && !(loopc % sysclocksync) ) { 119 124 gettimeofday(&ans, NULL); … … 135 140 if ( sysclocksync ) 136 141 loopc++; 142 #endif 137 143 } 138 144
Note: See TracChangeset
for help on using the changeset viewer.