Changeset 2847:403396142808 in roaraudio
- Timestamp:
- 10/04/09 01:33:30 (15 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roarclients/roarfilt.c
r2846 r2847 247 247 } 248 248 249 if ( bits == 16 ) { 250 while((i = roar_vio_read(&svio, buf, BUFSIZE))) { 251 if ( mul != div ) 252 vol2((void*)buf, mul, div, i); 253 #ifdef ROAR_HAVE_LIBM 254 if ( logscale ) 255 logs2((void*)buf, logscale, i); 256 if ( g_lowpass.a ) 257 lowpass2((void*)buf, i, channels); 258 #endif 259 roardsp_fchain_calc(&fc, (void*)buf, (8*i)/bits); 260 if (roar_vio_write(&svio, buf, i) != i) 261 break; 262 } 263 } else if ( bits == 8 ) { 264 while((i = roar_vio_read(&svio, buf, BUFSIZE))) { 265 vol1((void*)buf, mul, div, i); 266 if (roar_vio_write(&svio, buf, i) != i) 267 break; 268 } 269 } else { 270 fprintf(stderr, "Error: %i bits per sample is not supported!\n", bits); 271 return 1; 249 switch (bits) { 250 case 16: 251 while((i = roar_vio_read(&svio, buf, BUFSIZE))) { 252 if ( mul != div ) 253 vol2((void*)buf, mul, div, i); 254 #ifdef ROAR_HAVE_LIBM 255 if ( logscale ) 256 logs2((void*)buf, logscale, i); 257 if ( g_lowpass.a ) 258 lowpass2((void*)buf, i, channels); 259 #endif 260 roardsp_fchain_calc(&fc, (void*)buf, (8*i)/bits); 261 if (roar_vio_write(&svio, buf, i) != i) 262 break; 263 } 264 break; 265 case 8: 266 while((i = roar_vio_read(&svio, buf, BUFSIZE))) { 267 vol1((void*)buf, mul, div, i); 268 if (roar_vio_write(&svio, buf, i) != i) 269 break; 270 } 271 break; 272 default: 273 fprintf(stderr, "Error: %i bits per sample is not supported!\n", bits); 274 return 1; 272 275 } 273 276
Note: See TracChangeset
for help on using the changeset viewer.