https://bugzilla.novell.com/show_bug.cgi?id=363392 Summary: ALSA plugin type FILE: inline parameter (virtual mic), breaking sample rate pace Product: openSUSE 10.3 Version: Final Platform: All OS/Version: All Status: NEW Severity: Normal Priority: P5 - None Component: Sound AssignedTo: tiwai@novell.com ReportedBy: reisenweber@web.de QAContact: qa@suse.de Found By: Other virtual mic, as in ALSA type file plugin - parameter infile, is completely braindead! To show/reproduce: jr@panzermine:~> date;\ arecord -D tee:SLAVE="plughw:0,0",FILE=xxx -d 30 /dev/null;\ date Mi 20. Feb 18:08:00 CET 2008 Recording WAVE '/dev/null' : Unsigned 8 bit, Rate 8000 Hz, Mono Mi 20. Feb 18:08:31 CET 2008 ## we recorded 30 sec of audio via name tee plugin (a type file plugin) jr@panzermine:~> ls -l xxx -rw------- 1 jr users 240000 20. Feb 18:08 xxx ## 1byte * 8000/s * 30s = 240000 byte. arecord working quite accurate. ## now we use infile parameter to replace mic by file *): jr@panzermine:~> date;\ arecord -D intee:SLAVE="plughw:0,0",FILE=xxx -d 30 x.wav;\ date Mi 20. Feb 18:16:29 CET 2008 Recording WAVE 'x.wav' : Unsigned 8 bit, Rate 8000 Hz, Mono Mi 20. Feb 18:16:30 CET 2008 ## you see, arecord sampled "30 sec" in just one second. ## It simply copies input to output at max speed, not caring about ## pace of SLAVE plugin, which should give only 8000/s samples ################################## EXPECTED BEHAVIOUR: the above "arecord -D intee " cmd should take 30 seconds to finish! ERROR: infile is breaking pace of ALSA audio streams. ################################## jr@panzermine:~> arecord --version arecord: version 1.0.14 by Jaroslav Kysela <perex@suse.cz> *) intee above is from ~/.asoundrc: pcm.intee { @args.0 SLAVE @args.1 FILE @args.2 FORMAT @args.SLAVE { type string } @args.FILE { type string } @args.FORMAT { type string default raw } type file slave.pcm $SLAVE file /dev/null infile $FILE format $FORMAT } A second "bug": Also note: the command to sample 35 seconds jr@panzermine:~> date;\ arecord -D intee:SLAVE="plughw:0,0",FILE=xxx -d 35 x.wav;date Mi 20. Feb 18:36:09 CET 2008 Recording WAVE 'x.wav' : Unsigned 8 bit, Rate 8000 Hz, Mono Aborted by signal Unterbrechung... Mi 20. Feb 18:36:57 CET 2008 does NOT ever return (only on ^C). infile xxx delivers "30 sec" of sampled data, then reaches EOF. In this moment (0,5 sec after start!) the type FILE plugin seems to block arecord, instead of gracefully changing over to delivering samples from plughw:0,0 in realtime for another 5 seconds. :-( cheers jOERG -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.