Audio beakup

When playing videos I’ve made, as mp4 (720P/1080P) and DVD ISO images, the audio will occasionally breakup up, just for a split second. I use KDE 4.10.5 “release 1”, so I tried IceWM, and it happens there, too, sometimes seems even worse. Using openSuse 12.3 64 bit. I have no idea what causes this, I found no obvious settings to tweak. Is there a way to increase the “priority” (for lack of the proper term) for the audio? Or maybe a system function is interrupting the audio? I have a 6 core CPU, if that makes any difference. I don’t want to upgrade KDE or switch to openSuse 13.1 at this time, but maybe there’s any easier solution?

P.S. - This didn’t happen on openSuse 12.2, so it’s not the videos at fault.

I did some more tests, so I have corrected information:

I tried a DVD ISO home video, that played fine, so that might not be a problem…
The 720P video in question is an “.m2t” not mp4, so I’ll re-render to mp4 sometime and re-try. Also, this played fine with mplayer, the problem seems to be xine on that one.

I need to do more testing to be sure the above info is correct, but now I’m thinking it’s just a problem with xine, and / or the .m2t format. Those never were a problem in the past, though, and I don’t want to re-render all my old .m2t videos (but might anyway). I’ll return later when I have more info, but any suggestions are still welcome.

On 2014-02-16 19:46, HighBloodSugar wrote:

> I need to do more testing to be sure the above info is correct, but now
> I’m thinking it’s just a problem with xine, and / or the .m2t format.
> Those never were a problem in the past, though, and I don’t want to
> re-render all my old .m2t videos (but might anyway). I’ll return later
> when I have more info, but any suggestions are still welcome.

Try running xine from a terminal, perhaps with the --verbose switch. As
a wild guess, search to see if it says anything about “real time”.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

I tried the .m2t 720P video (29.97 fps by the way, if that matters), and it plays fine in mplayer. I also re-rendered it to H264 MP4, and it has the audio breakup in xine, but not in mplayer. So I guess I found the solution - use mplayer. I still have to try one of my long boring home video DVD ISOs in xine to see if those were really a problem, I may have been mistaken about those. I prefer xine for those, since mplayer doesn’t seem to recognize “chapters”. I’ll come back later after I try that, it’s a bit boring, so I won’t get to it right now. For what it’s worth, a “commercial” DVD as an ISO file worked fine in xine. Well, I didn’t play more than 5 minutes worth, but the problem usually happens before that. I have to play it all the way through to be sure.

Here’s what I see in the terminal:


user@linux-5sff:/data/HomeVideo-HighDef> xine --verbose TheOldBurialGround.m2t
This is xine (X11 gui) - a free video player v0.99.7.
(c) 2000-2010 The xine Team.
Built with xine library 1.2.3 (1.2.3)
Found xine library version: 1.2.3 (1.2.3).

<Removed CPU info, too much to post here>

main: probing <aadxr3> video output plugin
main: probing <dxr3> video output plugin
video_out_dxr3: Failed to open control device /dev/em8300-0 (No such file or directory)
main: probing <xv> video output plugin
video_out_xv: using Xv port 63 from adaptor Radeon Textured Video for hardware colour space conversion and scaling.
video_out_xv: this adaptor supports the YUY2 format.
video_out_xv: this adaptor supports the YV12 format.
video_out_xv: max XvImage size 8192 x 8192
main: probing <pulseaudio> audio output plugin
video_out: can't raise nice priority by 2: Operation not permitted
video_decoder: can't raise nice priority by 1: Operation not permitted
video_out: can't raise nice priority by 2: Operation not permitted
osd: error loading font sans with in XDG data directories.
osd: error loading font sans with in XDG data directories.
osd: error loading font sans with in XDG data directories.
video_decoder: can't raise nice priority by 1: Operation not permitted
video_decoder: can't raise nice priority by 1: Operation not permitted
xv_set_property: property=1, value=0
video_out_xv: VO_PROP_ASPECT_RATIO(0)
gui_xine_open_and_play():
        mrl: 'TheOldBurialGround.m2t',
        sub 'NONE',
        start_pos 0, start_time 0, av_offset 0, spu_offset 0.
xine: found input plugin  : file input plugin
xine: found demuxer plugin: MPEG Transport Stream demuxer
av_offset=0 pts
spu_offset=0 pts
video_out_xv:  b 0  c 0  s 0  [ITU-R 470 BG / SDTV]
Fontconfig warning: "/etc/fonts/conf.d/56-user.conf", line 9: reading configurations from ~/.fonts.conf is deprecated.
gui_xine_open_and_play():
        mrl: '/usr/share/xine/skins/xine-ui_logo.png',
        sub 'NONE',
        start_pos 0, start_time 0, av_offset 0, spu_offset 0.
xine: found input plugin  : file input plugin
xine: found demuxer plugin: image demux plugin
av_offset=0 pts
spu_offset=0 pts

Xine is using the xv backend, maybe that’s the problem?
What is mplayer using?

mplayer *videofile* |grep VO

Maybe try to install libxine2 from Packman (that one includes VDPAU support which the version from the standard repo doesn’t) and check that libvdpau_r600 is installed (should be by default).
Xine should use VDPAU (hardware decoding) then which might work better. If not, try to switch the video driver to VDPAU (or Auto should work as well) in Xine’s settings (“video” tab, you might have to raise the experience level setting on the “gui” tab for this option to show up though).

I have the packman version installed for xine, but I don’t have an nVidia card / chip, it’s integrated AMD video, so VDPAU won’t work. The video driver is set to auto.

Here’s what mplayer shows in the terminal:


user@linux-5sff:/data/HomeVideo-HighDef> mplayer TheOldBurialGround.m2t | grep V0
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
Fontconfig warning: "/etc/fonts/conf.d/56-user.conf", line 9: reading configurations from ~/.fonts.conf is deprecated.

[VD_FFMPEG] DRI failure.

I don’t know why it shows those errors, it plays the video just fine, and no audio problems. So, I’ll stick with mplayer for the videos. Still have to try a DVD ISO image all the way through using xine to see if those are ok, haven’t gotten to that yet.

With libvdpau_r600 installed VDPAU should work for AMD/ATI graphics based on R600 series chips, which yours is (RV620 to be precise).

But if you really have the Packman version installed, there should be a message about VDPAU on startup, which isn’t there in your post.
At least something like: (that’s on my system with a Radeon 9600 card)

Failed to open VDPAU backend libvdpau_r300.so: cannot open shared object file: No such file or directory
vo_vdpau: Can't create vdp device : No vdpau implementation.

So please show the output of:

rpm -qi libxine2

Here’s what mplayer shows in the terminal:

I don’t know why it shows those errors, it plays the video just fine, and no audio problems. So, I’ll stick with mplayer for the videos. Still have to try a DVD ISO image all the way through using xine to see if those are ok, haven’t gotten to that yet.

I guess mplayer falls back to the standard x11 output (i.e. software decoding, absolutely no hw acceleration) because of the errors.
Your CPU seems to be fast enough for that, so it’s working fine… :wink:

You could try to set xine’s video driver to “xshm” then as well. Or try any of the other options.

OTOH xine apparently is also using the “pulseaudio” audio driver. Maybe try to set that to “alsa”, even if you’re using pulseaudio (could be a bug in xine’s pulseaudio backend).
Or maybe even try to disable pulseaudio completely in YaST->Hardware->Sound->Other->PulseAudio Configuration to see if it’s related to pulseaudio.

On 2014-02-16 20:06, HighBloodSugar wrote:
> I tried the .m2t 720P video (29.97 fps by the way, if that matters), and
> it plays fine in mplayer. I also re-rendered it to H264 MP4, and it has
> the audio breakup in xine, but not in mplayer.

Not really a solution, both are using a video system that is slower and
needs more CPU to compensate.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))


linux-5sff:~ # rpm -qi libxine2
Name        : libxine2
Version     : 1.2.3
Release     : 89.3
Architecture: x86_64
Install Date: Thu Jan  2 16:22:34 2014
Group       : Productivity/Multimedia/Video/Players
Size        : 5716305
License     : GPL-2.0+
Signature   : RSA/SHA1, Mon Dec 23 16:29:31 2013, Key ID 45a1d0671abd1afb
Source RPM  : xine-lib-1.2.3-89.3.src.rpm
Build Date  : Mon Dec 23 11:54:19 2013
Build Host  : swkj07.site
Relocations : (not relocatable)
Packager    : packman@links2linux.de
Vendor      : http://packman.links2linux.de
URL         : http://www.xine-project.org/home
Summary     : Video Player with Plug-Ins
Description :
xine is a video player with a graphical front-end that supports a large
number of file formats (VCD and MPEG2, for example) using plug-ins.
Several plug-ins are included. Others can be installed after xine
installation. xine supports stereo sound using OSS and AC5.1 using
Alsa.

I must have left this out before:


load_plugins: plugin /usr/lib64/xine/plugins/2.3/xineplug_decode_vdpau_mpeg4.so found
main: probing <vdpau> video output plugin
Failed to open VDPAU backend libvdpau_r600.so: cannot open shared object file: No such file or directory
vo_vdpau: Can't create vdp device : No vdpau implementation.

I see libvdpau_r600, but after seeing this, I’m not going to install it:


 This is still "work in progress", i.e. expect poor video quality, choppy videos and artefacts all over.

I’ll try using the alsa setting in xine, though, seems safe. I’ll report back later…

PS, as I just noticed this:

This should be VO (the upper case letter o), not V0, so that output is not what I wanted to see.

Could you post the correct one again, please?

On 2014-02-16 20:56, wolfi323 wrote:
> OTOH xine apparently is also using the “pulseaudio” audio driver. Maybe
> try to set that to “alsa”, even if you’re using pulseaudio (could be a
> bug in xine’s pulseaudio backend).

I think there is a buffer size config somewhere in pulse :-?

In xine/setup/engine you can adjust the “number of audio buffers”, for
instance. Might help.

In the posted output xine mentions that it can not increase priority.
AFAIK this needs to be root, I don’t know if somehow a user can be
allowed that.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

OK.

I see libvdpau_r600, but after seeing this, I’m not going to install it:

This is still “work in progress”, i.e. expect poor video quality, choppy videos and artefacts all over.

That’s not quite true anymore. (IIRC this is actually the description of libvdpau_softpipe which got put into the other libvdpau_* packages as well by mistake or something like that)
On 13.1 the package description has changed to just:

This package contains the VDPAU state tracker for R600.

And if it gives problems, you can always just uninstall again.

But it has already solved problems with xine on R600 cards on 12.3 here in the forums a few times.

Oops! Here it is:


user@linux-5sff:/data/HomeVideo-HighDef> mplayer TheOldBurialGround.m2t | grep VO
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
VO: [xv] 1280x720 => 1280x720 Planar YV12  [zoom]
Fontconfig warning: "/etc/fonts/conf.d/56-user.conf", line 9: reading configurations from ~/.fonts.conf is deprecated.

[VD_FFMPEG] DRI failure.

Also, I set xine to use alsa instead of auto. Now the audio sound fine! :slight_smile:

Thanks for all the help! I never thought to try a different audio setting. Problem solved!

OK, mplayer is using xv as well, so this should rule out a problem with xv.

Also, I set xine to use alsa instead of auto. Now the audio sound fine! :slight_smile:

Thanks for all the help! I never thought to try a different audio setting. Problem solved!

Aha, so it was another pulseaudio issue.
You’re still using pulseaudio of course, not directly via xine’s pulseaudio plugin, but indirectly via alsa-plugins-pulse now.
Seems to work better in your case.

You could achieve the same by uninstalling libxine2-pulse and setting the audio driver back to “auto” btw. if you prefer.

I don’t use pulseaudio myself (I don’t even have it installed), so I can’t say whether this could be a general issue with xine’s pulse plugin or not.