Laptop: Thinkpad X1 Yoga 4th Gen OS: Fedora 34 and 35 Relevant Hardware: Laptop Webcam, USB HDMI Capture Card Relevant Apps: PipeWire (w/loopback module), OBS, Cheese, Discord, any webcam application
I’ve been having an issue where my webcam would no longer work on any app in my system when enabling the audio loopback module using either of:
pactl load-module module-loopback
pw-loopback
My setup when this happens is:
Use laptop webcam as a video source
USB HDMI Capture Card plugged in, capturing video and audio
Optional: Bluetooth Headset (audio sink), USB Antilion Mic (audio source), but I have the same issue without these
Enable loopback module
I stream/record games from my capture card, while also using the microphone and headset to talk to friends on Discord or in OBS. I want to be able to listen to the input audio of my Capture Card through my headphones, so that I can listen to game audio and a Discord call at the same time.
However, when I have my capture card and webcam connected, and enable the loopback module, my webcam is no longer available to apps to use as a video source. In apps like Discord and Cheese, it doesn’t even show up. All my audio inputs (including my webcam mic) are still functioning, but my webcam video no longer works. I’ve tried this without my headset or my mic plugged in, and just using my capture card and internal webcam/mic, and I still have the same issue.
My webcam continues to be unusable even if I disable the loopback module. However, if I unplug my capture card, then my webcam sometimes works again, but not always. A reboot without loading the loopback module will always fix it though.
I’ve tried this with both PipeWire and PulseAudio (by uninstalling PipeWire), and I get the same result in both, so it doesn’t look to be PipeWire specific. I find it strange that using an audio module will cause my webcam video to not work anymore.
/etc/pipewire doesn’t exist on my machine, so I imagine it’s just using the standard config files in /usr/share/pipewire.
I don’t know about the pw- tools, but I took a look and there’s a pw-loopback module. I don’t have any time to test it yet, but is there any benefit of using pw-loopback rather than the pactl loopback module?
There is a plusaudio module so, everything where is compatible with it should work. But if the service not works probably the loopback is also not working.
Of course if you can use pipewire without the pulsaudio plugin, it should work better. Pipewire is in development and things are getting better than with Pulsaudio.
That was the objective to move on to pipewire. Audio on Professional level will be possible more and more
All the services seem to be active and running on a cold boot with no errors. I’ve tried running both the pactl loopback module, as well as the PipeWire pw-loopback, and both result in my webcam no longer working, even after the loopback module is disabled.
I also tried uninstalling PipeWire and installing PulseAudio instead, but my webcam still wouldn’t work with the loopback module. So it looks like it may not be a PipeWire issue. Also, I looked at the audio monitors and all my input devices, including my webcam mic, were still working. So it looks like the loopback module results in my webcam video being no longer functional.
I looked at the pipewire status after running the loopback module and saw these error logs:
Nov 04 18:00:11 lawrence-x1y4-fedora pipewire[1987]: spa.alsa: set_hw_params: No space left on device
Nov 04 18:00:11 lawrence-x1y4-fedora pipewire[1987]: pw.node: (alsa_input.usb-Antlion_Audio_Antlion_Wireless_Microphone-00.pro-input-0-49) suspended -> error (Start error: No space lef
t on device)
Nov 04 18:00:11 lawrence-x1y4-fedora pipewire[1987]: spa.alsa: set_hw_params: No space left on device
Nov 04 18:00:27 lawrence-x1y4-fedora pipewire[1987]: pw.link: 0x558a05baeac0: one of the nodes is in error out:error in:suspended
Not sure what to make of these, especially since my audio inputs were still working, it’s just my webcam video that isn’t working.
Don’t think I have a memory card on my mic, it’s just a USB receiver. However, I just tried it without my bluetooth headset or my USB mic, using just my USB Capture Card, my webcam, and the loopback module playing audio from my capture card to my laptop speakers. It still results in my webcam video not working.
I’ve also updated my initial post to give better/specific details.
I’m using a Thinkpad X1 Yoga 4th Gen, with an i5-8265U and 16GB ram. I’m using Fedora 35 but I also had this problem recently on Fedora 34.
You truncated the output for posting. We did not get anything related to the webcam.
Please post the entire output so we can see all the potentially related pieces.
Ah my bad, I didn’t want to make a huge post with a long log, I didn’t realize it would automatically make it scrollable. Here’s the full log of just my laptop with my capture card plugged in. I didn’t include my headset or my mic since the bug still persists without those plugged in.
Also, as a note, I have tried this again on a fresh live boot of Fedora 34 on this laptop, as well as clean installs of Fedora 35 and Pop OS 21.10 Beta on a different Lenovo Thinkpad 13 (i5-7500u). In all 3 cases, I was able to have loopback audio from my capture card while using my webcam in Cheese.
I’m wondering if something got messed up on my webcam config somewhere. I’m tempted to just reinstall Fedora 35 on this machine, but I want to see if there’s a way to fix this without doing that.
Try creating a new user and check if everything works as expected when logged in as that user. If it does then something in your user config is interfering. If it still acts the same then we need to track down the actual cause outside of your user config.
Just created a new user and plugged in my capture card, then loaded pw-loopback. I opened Cheese, and it gave the same error screen that says “There was an error playing video from your webcam.” So looks like it’s not just a user config thing.
I decided to try Fedora 35 on this laptop again (Thinkpad X1 Yoga 4th Gen)… I was having the same webcam issue when using the pw-loopback module. An old Fedora 34 iso (kernel 5.11.12-300), however, worked fine, and I was able to listen to capture card audio with loopback while viewing my webcam in Cheese.
I decided to try Fedora 34 and 35 on my Thinkpad 13 2nd Gen… and both of them worked fine. I don’t know if the webcam hardware differs, but I do know that the X1Y4 has a 4 mic arragement, while the 13 only has a 2 mic arrangement.
So looks like it’s an issue with the webcam hardware in my Thinkpad X1 Yoga 4th Gen, Maybe there was a regression introduced during a kernel update, since my older Fedora 34 iso still worked fine? I had this issue before updating to Fedora 35, so I don’t think it had to do with the update to 35.
I tried loading an older kernel from the Grub menu, but the only options available were two of the Fedora 35 kernels (5.14.14-300), and then a very recent Fedora 34 kernel (5.14.14-200) which resulted in the same error.
Is there any other insight that might help me get this fixed for my machine? Since it didn’t work on a Fedora 35 live boot on my X1T4 (but DID work on a live boot of Fedora 34), but DID work on a Fedora 35 live boot on my Thinkpad 13 2nd Gen, I’m thinking it’s a bug that got introduced in an update that only applies to my hardware (and other X1 laptops with similar webcam/mic arrangements).