You are not logged in.

#1 2023-01-22 10:06:00

aardwolf
Member
From: Belgium
Registered: 2005-07-23
Posts: 304

[SOLVED] Choppy audio when using digital output with pulseaudio

Hi,

My motherboard's built-in audio presents itself as "Digital Output (S/PDIF) USB Audio" (so it's USB despite being built-in the motherboard), and pulseaudio seems to be very choppy with this.

Most applications work fine, but VLC player specifically is very choppy when using this audio output. The other possible output is HDMI/Displayport audio, but that goes to very bad built-in monitors speakers and is not what I want to use. However, with that one VLC is not choppy.

The choppyness with VLC is not only the audio, the entire video pauses for half a second, then plays for half a second, and so on repeatedly.

I have many questions about this:

-how could the built-in audio be choppy in VLC while HDMI not? Isn't pulseaudio a layer in-between that should handle audio, while VLC only passes the audio to pulseaudio? Why does the device pulseaudio is outputting to matter for VLC?

-is it possible to remove pulseaudio from the system and use only alsa, or is that not possible because some applications require pulseaudio today? pulseaudio has actually always had problems for me over the last 10 years (how does something that should be playing audio for you manage to *pause* movies in both media players and browsers just by opening the audio settings dialog, for example? or have things you do in one application disrupt playback in another but only when it feels like it?), while alsa before pulseaudio was a thing never had a single issue (once it's set up it just kept working and working) so I'd actually be pretty happy if it's realistically possible to not have to depend on this dumpster fire that invented bugs and problems that shouldn't even exist

-any other methods that may make pulseaudio not cause some applications to be choppy when using USB audio output?

Thanks!

Last edited by aardwolf (2023-01-22 17:03:52)

Offline

#2 2023-01-22 11:42:25

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,680
Website

Re: [SOLVED] Choppy audio when using digital output with pulseaudio

aardwolf wrote:

pulseaudio seems to be very choppy

https://wiki.archlinux.org/title/PulseA … _crackling?

aardwolf wrote:

is it possible to remove pulseaudio from the system and use only alsa, or is that not possible because some applications require pulseaudio today?

VLC works fine for me with pure ALSA, even when streaming videos to a Chromecast device. I only ever need a sound server for video conferencing. The Firefox package in Arch is compiled with the --enable-alsa option so it also works fine without PA. I know the Mozilla tarball version needs a sound server though and I have no idea about chromium.

Offline

#3 2023-01-22 12:23:19

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,427

Re: [SOLVED] Choppy audio when using digital output with pulseaudio

On a normal  USB device you should also have an analog output, are you knowingly using the digital out because you are actually using a digital coax cable? If not check whether changing the device profile to an analog variant helps (check the config section in e.g. pavucontrol). Also VLC is in general a special case since it will do audio processing on it's own instead of passing it to pulseaudio unaltered which might introduce unnecessary resample/configuration passes

If that doesn't help, during reproduction of the issue post

pactl list cards
pactl list sinks
pactl list sink-inputs

Another option that some people are jumping on that might fix some things is switching out pulseaudio for pipewire-pulse in order to use pipewire instead

Last edited by V1del (2023-01-22 12:32:23)

Offline

#4 2023-01-22 13:44:44

aardwolf
Member
From: Belgium
Registered: 2005-07-23
Posts: 304

Re: [SOLVED] Choppy audio when using digital output with pulseaudio

I tried:

pulseaudio -k
pulseaudio --start

and that made VLC not choppy anymore (so pulseaudio has bugs that fix themselves after restarting, 10 years of existance and it has this kind of bugs for something that should be, especially for my use case, as simple as "just play the audio that programs play", like alsa did), but on the other hand the audio volume icon in cinnamon disappeared and didn't come back until I rebooted, so this was a useless exercise

I installed pipewire now and it works (currently, let's see how long this one can keep itself stable).

I also see that there is indeed a USB analog option next to the digital one. Both work (I use the audio jack plug).

That's no excuse for the bugs in the digital one though, some people need to use that one I assume and they'll have these issues?

Last edited by aardwolf (2023-01-22 14:29:58)

Offline

Board footer

Powered by FluxBB