Opened 16 years ago

Closed 16 years ago

#934 closed defect (fixed)

pulseaudio plugin very slow when not using native protocol

Reported by: avuton@… Owned by: reimar
Priority: normal Component: ao
Version: HEAD Severity: normal
Keywords: Cc:
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

When using pulseaudio to play a HD video, it begins going very, very slow if I specify a hostname/output in the following format (uses about 20% CPU, but continues to skip sporadically):

But, if I do the following everything goes very smoothly:

sbh@rocket ~ $ mplayer -ao pulse [NAME OF VIDEO REMOVED]
MPlayer dev-SVN-rUNKNOWN-4.1.2 (C) 2000-2007 MPlayer Team
CPU: Intel(R) Core(TM)2 CPU 6420 @ 2.13GHz (Family: 6, Model: 15, Stepping: 6)
CPUflags: MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled for x86 CPU with extensions: MMX MMX2 SSE SSE2

Playing [NAME OF VIDEO REMOVED]
[mkv] Track ID 1: audio (A_AC3), -aid 0, -alang und
[mkv] Track ID 2: video (V_MPEG4/ISO/AVC), -vid 0
[mkv] Will play video track 2.
Matroska file format detected.
VIDEO: [avc1] 1280x720 24bpp 23.976 fps 0.0 kbps ( 0.0 kbyte/s)
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [liba52] AC3 decoding with liba52
Using SSE optimized IMDCT transform
Using MMX optimized resampler
AUDIO: 48000 Hz, 2 ch, s16le, 384.0 kbit/25.00% (ratio: 48000->192000)
Selected audio codec: [a52] afm: liba52 (AC3-liba52)
==========================================================================
AO: [pulse] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
VDec: vo config request - 1280 x 720 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.78:1 - prescaling to correct movie aspect.
VO: [xv] 1280x720 => 1280x720 Planar YV12
A: 10.1 V: 10.1 A-V: 0.001 ct: 0.000 244/244 32% 2% 1.1% 0 0

If I output to the same exact output, but specified I get:

mplayer -ao pulse:localhost:alsa_output.pci_1102_2_alsa_playback_0 [NAME OF VIDEO REMOVED]

MPlayer dev-SVN-rUNKNOWN-4.1.2 (C) 2000-2007 MPlayer Team
CPU: Intel(R) Core(TM)2 CPU 6420 @ 2.13GHz (Family: 6, Model: 15, Stepping: 6)
CPUflags: MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled for x86 CPU with extensions: MMX MMX2 SSE SSE2

Playing [NAME OF VIDEO REMOVED]
[mkv] Track ID 1: audio (A_AC3), -aid 0, -alang und
[mkv] Track ID 2: video (V_MPEG4/ISO/AVC), -vid 0
[mkv] Will play video track 2.
Matroska file format detected.
VIDEO: [avc1] 1280x720 24bpp 23.976 fps 0.0 kbps ( 0.0 kbyte/s)
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [liba52] AC3 decoding with liba52
Using SSE optimized IMDCT transform
Using MMX optimized resampler
AUDIO: 48000 Hz, 2 ch, s16le, 384.0 kbit/25.00% (ratio: 48000->192000)
Selected audio codec: [a52] afm: liba52 (AC3-liba52)
==========================================================================
AO: [pulse] 48000Hz 2ch s16le (2 bytes per sample)
Starting playback...
VDec: vo config request - 1280 x 720 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.78:1 - prescaling to correct movie aspect.
VO: [xv] 1280x720 => 1280x720 Planar YV12
A: 14.2 V: 14.1 A-V: 0.025 ct: -0.022 340/340 35% 2% 0.7% 22 0

Non-developer bug reporters should never make assumptions, but I'm going to here, so please opt out if you wish :).

This leads me to believe that when localhost is specified, it does not necessarily go over the native protocol, so I cannot send audio to an alternative output without having to construct tcp packets, which causes syncing or some kind of problem in mplayer.

Change History (2)

comment:1 by avuton@…, 16 years ago

More details:

This is revision: 24929

Config files successfully generated by ./configure --cc=x86_64-pc-linux-gnu-gcc --host-cc=x86_64-pc-linux-gnu-gcc --prefix=/usr --confdir=/etc/mplayer --datadir=/usr/share/mplayer --libdir=/usr/lib64 --enable-largefiles --enable-menu --enable-network --disable-tv-bsdbt848 --disable-faad-external --disable-fribidi --disable-enca --disable-vstream --disable-libcdio --disable-ass --charset=UTF-8 --disable-lirc --disable-lircc --disable-joystick --disable-inet6 --disable-smb --disable-dvb --disable-dvbhead --disable-tv-v4l1 --disable-tv-teletext --disable-pvr --disable-radio-v4l2 --disable-radio-bsdbt848 --disable-musepack --disable-pnm --disable-tga --disable-libamr_nb --disable-libamr_wb --xanimcodecsdir=/usr/lib/xanim/mods --realcodecsdir=/usr/lib64/codecs --disable-directfb --disable-ivtv --disable-ggi --disable-aa --disable-dga1 --disable-dga2 --disable-fbdev --disable-caca --disable-vesa --disable-vidix-internal --disable-vidix-external --disable-zr --enable-gui --enable-xvmc --with-xvmclib=XvMCW --disable-3dfx --disable-tdfxvid --disable-tdfxfb --disable-arts --disable-esd --disable-jack --disable-ladspa --disable-nas --disable-ossaudio --disable-ssse3 --disable-altivec !

Install prefix: /usr
Data directory: /usr/share/mplayer
Config direct.: /etc/mplayer

Byte order: little-endian
Optimizing for:

Languages:

Messages/GUI: en
Manual pages: en

Enabled optional drivers:

Input: ftp tv-v4l2 tv live555 cddb cdda libdvdcss(internal) dvdread(internal) vcd network
Codecs: x264 xvid libdv libavcodec real xanim faad2 faac libmpeg2 libdca liba52 mp3lib libtheora speex tremor(internal) twolame libmad liblzo gif
Audio output: alsa openal pulse v4l2 sdl mpegpes(file)
Video output: v4l2 sdl gif89a jpeg png mpegpes(file) opengl xvmc xv x11 xover md5sum
Audio filters:

Disabled optional drivers:

Input: dvdnav vstream pvr radio tv-teletext tv-v4l1 tv-dshow nemesi dvb smb
Codecs: libamr_wb libamr_nb qtx win32 musepack toolame
Audio output: sun jack esd arts oss ivtv dxr2 nas
Video output: ivtv dxr3 dxr2 vesa pnm zr zr2 fbdev svga caca aa ggi xmga mga xvidix winvidix cvidix 3dfx dga dfbmga directfb bl tga xvr100 tdfx_vid s3fb tdfxfb
Audio filters: ladspa

'config.h' and 'config.mak' contain your configuration options.
Note: If you alter theses files (for instance CFLAGS) MPlayer may no longer

compile * DO NOT REPORT BUGS if you tweak these files *

comment:2 by reimar, 16 years ago

Resolution: fixed
Status: newclosed

Use latest SVN and -ao pulse::alsa_output.pci_1102_2_alsa_playback_0

Note: See TracTickets for help on using tickets.