Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Electron/Chrome ignores selected microphone [Debian based with pipewire] #15

Closed
Andy-Danderson opened this issue Jan 18, 2024 · 15 comments
Assignees
Labels
bug Something isn't working upstream The issue is caused by an upstream vendor

Comments

@Andy-Danderson
Copy link

Andy-Danderson commented Jan 18, 2024

Describe the bug
It is neither possible to stream audio from a specific window, nor receive anything other than mic audio with "Entire System" selected, when using Vesktop on Linux Mint 21.2.

To Reproduce
Steps to reproduce the behavior:

  1. Be on Mint 21.2 Cinnamon (with
  2. Follow this guide to install Pipewire (you may need to restart a couple times): https://forums.linuxmint.com/viewtopic.php?t=375771
  3. Join a voice chat on Vesktop
  4. Click "share a screen" and choose a window to stream
  5. On the next screen, note that the only selectable audio path is "Entire System"
  6. Choose it and, behold, you get a clone of only your mic and literally nothing else.

Expected behavior
It should be possible to choose anything other than "Entire System." "Entire System" should also have more than just your mic sounds (but presumably no sounds from Vesktop itself).

Screenshots
image

Desktop (please complete the following information):

  • OS/Distro: Mint
  • Desktop Environment: Cinnamon
  • Version: 21.2

Additional context
Please fix, I've been trying to find a way to screenshare for two months and this is the closest I've gotten :(

EDIT: I found a video that shows what the problem seems to be using Helvum: video

@Andy-Danderson Andy-Danderson added the bug Something isn't working label Jan 18, 2024
@Vendicated Vendicated transferred this issue from Vencord/Vesktop Jan 18, 2024
@Curve
Copy link
Member

Curve commented Jan 20, 2024

@Andy-Danderson Please provide the necessary logs as seen here: https://github.com/Vencord/venmic#-debugging

Please also state your pipewire and vesktop version

@Curve
Copy link
Member

Curve commented Jan 20, 2024

@Vendicated I'm not sure why this would happen though - It seems like Vesktop is not able to find venmic and chooses the normal microphone instead? I kind of doubt this is a venmic issue, but rather a vesktop issue

@Curve
Copy link
Member

Curve commented Jan 20, 2024

Hmm, can confirm that the PR above does not fix the issue.

The venmic-node is found, however it seems that something on Linux Mint prevents Discord from grabbing the audio from said node.

With PR applied:

image
image

No idea why Chromium doesn't pull audio from the given source

@Curve
Copy link
Member

Curve commented Jan 20, 2024

This looks like a problem with Chromium on Mint to me. I can even reproduce this with the microphone selection in the settings, regardless of which device I choose, it will always use the system default no matter what

@Curve
Copy link
Member

Curve commented Jan 20, 2024

Peek_2024-01-20_16-15.mp4

This is def. an issue with the pipewire setup on Mint, happens with Firefox as well - I have no clue what causes this.
Issue seems to be that regardless of what Microphone I select, it will always use the default microphone on Mint (Tested in Firefox and Vesktop).

@Curve Curve added the upstream The issue is caused by an upstream vendor label Jan 20, 2024
@Curve
Copy link
Member

Curve commented Jan 24, 2024

Some more relevant information is available in #15.

Also loki-47-6F-64/sunshine#298 seems related, however it seems the issue there is not strictly related to Debian installs and seems to be faulty on Arch instead, which I cannot confirm/reproduce. I can only observe this behavior in a Debian based VM with pipewire installed from the PPA

@Curve Curve changed the title Screenshare with audio does not work properly on Linux Mint 21.2 (w/ Pipewire installed) Electron/Chrome ignores selected microphone [Debian based with pipewire] Jan 24, 2024
@Curve
Copy link
Member

Curve commented Jan 24, 2024

@mhkdepauw can you reproduce what I showed in the video above?

It demonstrates that Firefox ignores the selected microphone as well which further indicates a pipewire issue - funnily enough only on Debian based systems though - not reproducible on arch

@mhkdepauw
Copy link

Yep I just tested it and it does only use the microphone set in the system settings and not in firefox. Do you need me to make a video of that or is me just saying it enough, I can if you wanted.

@Curve
Copy link
Member

Curve commented Jan 24, 2024

Yep I just tested it and it does only use the microphone set in the system settings and not in firefox. Do you need me to make a video of that or is me just saying it enough, I can if you wanted.

Confirmation suffices, thanks!

@Curve
Copy link
Member

Curve commented Jan 24, 2024

I've now implemented a workaround that forcefully redirects discords record-stream to venmic.

The implementation for Vesktop is also done, we'll have to wait ~1h for the publish workflow to finish now and then we're good to go

@TheAnnoyingFruit
Copy link

Just leaving this here for anyone looking for it, the fix does not work on the flatpak. Then you will have the dependency being too old issue on the deb and the fix is linked where it will tell you how to install the newer version which works. This is all sorts of aids.

@Curve
Copy link
Member

Curve commented Mar 30, 2024

Just leaving this here for anyone looking for it, the fix does not work on the flatpak. Then you will have the dependency being too old issue on the deb and the fix is linked where it will tell you how to install the newer version which works. This is all sorts of aids.

The fix should work with Flatpak as well, if it doesn't please open a new issue.

@githubplanetarparrot
Copy link

Hey I just installed Ventcord on Mint and am having this issue still. Reviewing video https://youtu.be/UgfW-0UjVlA I still have the issue even when the workaround is toggled on (if it is toggled off the mic looping issue occurs despite helvum looking the same regardless of the workaround being on or off). I have ventcord installed via flatpak and am on the latest release as of today. Is the only way to manually correct this issue to manually editing helvum every time?

image

I know this is an old issue and you said to make a new one, but I want to make sure I am understanding that the workaround button is only for fixing the loopback and helvum is basically required at this time for all mint users or if my setup is messed up/I have a new issue.

@Curve
Copy link
Member

Curve commented Jun 12, 2024

Can you share the venmic log as well? And another screenshot of helvum with the workaround toggled on (or is that the case in - the screenshot?)

@githubplanetarparrot
Copy link

So unfortunately I can't any more screenshots as I removed the flatpak version. I was actually able to fix this issue on Mint by using the debian version provided here: https://github.com/Vencord/Vesktop
I was able to properly get Vesktop audio share working on linux by doing the following steps. I am listing them here so some other poor Mint noob like me in the future can see what I did.

  1. Install pipewire per this article. Note I simply added the ppa:pipewire-debian/pipewire-upstream in step one using Mint's software sources to avoid issues with keyrings. https://linuxconfig.org/how-to-install-pipewire-on-ubuntu-linux
  2. Install Vesktop via the appropriate Debian file on https://github.com/Vencord/Vesktop
  3. Install the libstdc fix listed in https://gist.github.com/Vendicated/b655044ffbb16b2716095a448c6d827a. Again, I added the repo ppa:ubuntu-toolchain-r/test via the Software Sources menu, not the apt command, then run the second and third commands in terminal.
  4. Restart Vesktop.
  5. Set both input and output to "default" in vesktop
  6. Ensure your system sound (your desktop level device, not the vesktop device) is using your standard mic and not the vesktop virtual device.
  7. Start the application you wish to screen share. Ensure sound is playing so it will appear in the applications list.
  8. Attempt to screen share with the workaround option enabled. Select the appropriate screen and audio device and it should work.

System:
Kernel: 6.5.0-35-generic x86_64 bits: 64 compiler: N/A Desktop: Cinnamon 6.0.4 tk: GTK 3.24.33
wm: muffin vt: 7 dm: LightDM 1.30.0 Distro: Linux Mint 21.3 Virginia base: Ubuntu 22.04 jammy

I can reinstall the flatpak version to recreate if you would really like me to as I want to do whatever I can to assist. My uneducated guess is that since Mint doesn't have the gnome popups for flatpaks to request permissions that proper mic device access isn't being enabled within the flatpak (issue described here https://forums.linuxmint.com/viewtopic.php?t=379456). I believe a workaround may be here wwmm/easyeffects#1802 relating to xdg-desktop-portal-gnome, but this is just a guess.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working upstream The issue is caused by an upstream vendor
Projects
None yet
Development

No branches or pull requests

6 participants