[vlc-devel] Alsa buffer duration. Invalid argument.

Peter Tap ptrtap at yahoo.com
Thu Oct 25 07:42:07 CEST 2012

For now, I edited alsa.c and commented out the call to snd_pcm_hw_params_set_buffer_time_near. Now my 5.1 sound is back. I am wondering if commenting it may cause any other problem. The custom vlc is going to run only on a specific motherboard and nvidia card.

I am still hoping that someone has a better solution. I don't understand why the packaged vlc works and mine doesn't:-(.



----- Original Message -----
From: Peter Tap <ptrtap at yahoo.com>
To: Mailing list for VLC media player developers <vlc-devel at videolan.org>
Sent: Wednesday, October 24, 2012 5:00 PM
Subject: [vlc-devel] Alsa buffer duration. Invalid argument.


On my Ubuntu 12.04 box, I have installed vlc package (version 2.0.3). I also have my custom vlc installed in a separate directory. The custom vlc is built using 2.0.4 codebase that is available for download.

Both the versions are configured to use ALSA 5.1 surround channels.

When I run packaged version of vlc, all my speakers work as expected.

When I run my custom version of vlc,  I do not get any sound.

Looking at verbose mode, I see an error that alsa cannot set buffer duration. Here is the relevant text: 

[0x7f0c3c14fea8] alsa audio output debug: keeping 6 channels
[0x7f0c3c14fea8] alsa audio output debug: using ALSA device: surround51:CARD=PCH,DEV=0
[0x7f0c3c14fea8] alsa audio output debug:  Soft volume PCM
Control: PCM Playback Volume
min_dB: -51
max_dB: 0
resolution: 256
Slave: Hardware PCM card 0 'HDA Intel PCH' device 0 subdevice 0
[0x7f0c3c14fea8] alsa audio output debug:  device name   : ALC892 Analog
[0x7f0c3c14fea8] alsa audio output debug:  device ID     : ALC892 Analog
[0x7f0c3c14fea8] alsa audio output debug:  subdevice name: subdevice #0
[0x7f0c3c14fea8] alsa audio output debug: initial hardware setup:
SAMPLE_BITS: [16 32]
FRAME_BITS: [32 192]
RATE: [44100 192000]
PERIOD_TIME: (31 185760)
PERIOD_SIZE: [6 8192]
PERIOD_BYTES: [24 196608]
PERIODS: [2 32]
BUFFER_TIME: (62 371520)
BUFFER_SIZE: [12 16384]
BUFFER_BYTES: [48 393216]
[0x7f0c3c14fea8] alsa audio output error: cannot set buffer duration: Invalid argument

When I compare this with the output from packaged vlc, all the lines up to the last line are identical. However, in my case, I get an error that is shown in the last line.

I am wondering if anyone knows why I might be getting this error.

Thank you in advance for your help.

vlc-devel mailing list
To unsubscribe or modify your subscription options:

More information about the vlc-devel mailing list