A custom discord client that supports streaming with audio on Linux.
Go to file
Malte Jürgens 4b782133ae
Merge branch 'arrpc'
2023-03-04 13:15:11 +01:00
assets Merge branch 'arrpc' 2023-03-04 13:15:11 +01:00
scripts testing arrpc server 2023-03-02 16:43:42 +01:00
src Merge branch 'master' into arrpc 2023-03-02 17:23:08 +01:00
submodules remove channel submodule 2023-03-02 17:29:10 +01:00
.gitignore remove arrpc submodule 2023-03-02 17:25:00 +01:00
.gitmodules use rohrkabel as submodule and update it to v1.2 2022-07-26 16:33:34 +02:00
CMakeLists.txt show userstyles status on the bottom of the page 2023-02-17 16:20:29 +01:00
LICENSE fix license 2022-07-18 21:07:10 +02:00
README.md fix path for flatpak in faq 2023-02-19 00:38:33 +01:00
resources.qrc testing arrpc server 2023-03-02 16:43:42 +01:00
version.cmake cmake: use version from text file without suffix 2022-08-04 15:47:04 +02:00

README.md

discord-screenaudio

A custom discord client that supports streaming with audio on Linux, made possible by the great work of @edisionnano and the Rohrkabel library by @Curve.

Unlike a lot of other solutions, the audio here is directly fed into the screenshare and not passed to the user microphone (see explanation).

Screenshot_20221211_185028

The purpose of this project is not to provide an alternative to the original Discord client. Rather, it should be used in addition to the original client in case you want to stream something, maybe used with a second account. For anything else, this client has way too many things that work less well than in the original client.

Technically this could be against Discord's TOS, so be warned. Discord probably won't ban you for using this, but if they do I told you and it's not my fault.

Known Issues

  • Only works with PipeWire
  • Can only share primary screen on X11 (no other screens or specific applications) (see #1)

Installation

You have multiple options:

Building from Source

Requirements

  • Basic building tools
  • An up-to-date system (I can't guarantee that it works on Debian or Ubuntu 20/21)
  • CMake
  • Qt5 and QtWebEngine
  • PipeWire (it currently doesn't work with PulseAudio)
  • Git
  • Kf5Notifications (optional, for better notifications)
  • KXMLGui and KGlobalAccel (optional, for keybinds)

With apt: apt install -y build-essential cmake qtbase5-dev qtwebengine5-dev libkf5notifications-dev libkf5xmlgui-dev libkf5globalaccel-dev pkg-config libpipewire-0.3-dev git

Building

First, clone the repository:

git clone https://github.com/maltejur/discord-screenaudio.git
cd discord-screenaudio

Then, to build the program, run this in the source directory:

cmake -B build
cmake --build build --config Release

And then to optionally install it, run:

sudo cmake --install build

FAQ

How does this work?

This whole project is based on this repository, which very nicely explains how to stream audio in the web version of Discord. Basically: a virtual microphone is created which captures the application audio, and this microphone is then fed to the Discord stream by intercepting a API call of Discord.

Drag and drop doesn't work in the Flatpak

This is due to sandboxing limitations of Flatpak. The main Discord Flatpak has the same problem. If you still want to use drag and drop, you can disable most of Flatpak's sandboxing by installing Flatseal and allowing access to "All system files" under the "Filesystem" section.

Is there any way to add custom CSS / a theme?

Yes, you can add all your styles into ~/.config/discord-screenaudio/userstyles.css (or ~/.var/app/de.shorsh.discord-screenaudio/config/discord-screenaudio/userstyles.css if you are using the Flatpak). But please note that due to QtWebEngine limitations concerning content security policies, you can't use any external files (like @import or url()).

License

Copyright (C) 2022 Malte Jürgens

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.