[MPlayer-users] Jerky, jumping sound with -af volume and -ao pulse|alsa|oss playing a pcm stream
Ilja Sekler
ilja_sekler_ at gmx.de
Mon May 25 19:10:44 CEST 2009
Hello,
my Hauppauge PVR250 MPEG2 encoder card (driver: ivtv) can receive radio,
the PCM stream (2ch, 48kHz) is available as /dev/video24. As the volume
level is very low, I correct this by adding
-af volume=14:0
option to the MPlayer command line. Unfortunately, the sound begins to
jump back and forth soon. This doesn't happen without the "volume"
filter or writing the stream e.g. with dd to a file on the HDD first and
then playing this file.
########################################################################
mplayer -v -cache 2048 -af volume=14:0 -demuxer rawaudio -rawaudio
bitrate=48000:channels=2 /dev/video24
MPlayer SVN-r29314-4.3.3 (C) 2000-2009 MPlayer Team
CPU vendor name: AuthenticAMD max cpuid level: 1
CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 4200+ (Family: 15, Model:
75, Stepping: 2)
extended cpuid-level: 24
extended cache-info: 33587520
Detected cache-line size is 64 bytes
Testing OS support for SSE... yes.
Tests of OS support for SSE passed.
CPUflags: MMX: 1 MMX2: 1 3DNow: 1 3DNowExt: 1 SSE: 1 SSE2: 1 SSSE3: 0
Compiled for x86 CPU with extensions: MMX MMX2 3DNow 3DNowExt SSE SSE2 CMOV
get_path('codecs.conf') -> '/home/ilja/.mplayer/codecs.conf'
Reading /home/ilja/.mplayer/codecs.conf: 137 audio & 296 video codecs
Configuration: --prefix=/usr --enable-menu --disable-rtc --disable-lirc
--disable-x264 --disable-arts --disable-gui --target=i686-linux
--confdir=/etc/mplayer
CommandLine: '-v' '-cache' '2048' '-af' 'volume=14:0' '-demuxer'
'rawaudio' '-rawaudio' 'bitrate=48000:channels=2' '/dev/video24'
init_freetype
get_path('font/font.desc') -> '/home/ilja/.mplayer/font/font.desc'
font: can't open file: /home/ilja/.mplayer/font/font.desc
font: can't open file: /usr/share/mplayer/font/font.desc
Using MMX (with tiny bit MMX2) Optimized OnScreenDisplay
get_path('fonts') -> '/home/ilja/.mplayer/fonts'
Using nanosleep() timing
get_path('input.conf') -> '/home/ilja/.mplayer/input.conf'
Parsing input config file /home/ilja/.mplayer/input.conf
Input config file /home/ilja/.mplayer/input.conf parsed: 1 binds
get_path('video24.conf') -> '/home/ilja/.mplayer/video24.conf'
Playing /dev/video24.
get_path('sub/') -> '/home/ilja/.mplayer/sub/'
[file] File size is 0 bytes
STREAM: [file] /dev/video24
STREAM: Description: File
STREAM: Author: Albeu
STREAM: Comment: based on the code from ??? (probably Arpi)
CACHE_PRE_INIT: 0 [0] 0 pre:419430 eof:0
Cache fill: 18.75% (393216 bytes)
rawaudio file format detected.
==> Found audio stream: 0
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
dec_audio: Allocating 2048 + 65536 = 67584 bytes for output buffer.
AUDIO: 44100 Hz, 2 ch, s16le, 48.0 kbit/3.40% (ratio: 6000->176400)
Selected audio codec: [pcm] afm: pcm (Uncompressed PCM)
==========================================================================
Building audio filter chain for 44100Hz/2ch/s16le -> 0Hz/0ch/??...
[libaf] Adding filter volume
Trying preferred audio driver 'pulse', options '[none]'
[pulse] working around probably broken pause functionality,
see http://www.pulseaudio.org/ticket/440
AO: [pulse] 44100Hz 2ch s16le (2 bytes per sample)
AO: Description: PulseAudio audio output
AO: Author: Lennart Poettering
Building audio filter chain for 44100Hz/2ch/s16le -> 44100Hz/2ch/s16le...
Video: no video
Freeing 0 unused video chunks.
Starting playback...
Increasing filtered audio buffer size from 0 to 46144
Uninit audio filters....0 (unknown) 0.2% 49%
[libaf] Removing filter volume
Uninit audio: pcm
vo: x11 uninit called but X11 not initialized..
Exiting... (Quit)
########################################################################
Increasing the value for -cache makes the time before the problem occurs
considerably longer. With 2048, the sound works fine for about a minute,
then starts to crackle and to jump. I get about 15 min. with 60000.
Interesting enough, a wave file "radio.wav" generated with
-ao pcm:file=radio.wav
is free of crackles or jumps. So it could be a driver issue too. At the
same time, something like
mplayer -really-quiet -cache 1024 -af volume=14:0 \
-demuxer rawaudio -rawaudio bitrate=48000:channels=2 \
-ao pcm:file=/dev/stdout /dev/video24 | mplayer -cache 1024 -
doesn't help.
Linux distribution: Ubuntu 9.04.
I realize that this problem may be very difficult to reproduce without a
similar hardware... I'd like to avoid the obvious workaround writing the
sound output into a wave file and opening another instance of MPlayer a
couple of seconds later to play it.
Thanks for reading!
--
Regards
Ilja
More information about the MPlayer-users
mailing list