2022-07-07 13:11:51 +02:00
|
|
|
#include "mainwindow.h"
|
2022-07-09 22:07:14 +02:00
|
|
|
#include "virtmic.h"
|
|
|
|
|
2022-07-07 13:11:51 +02:00
|
|
|
#include <QApplication>
|
2022-07-09 22:07:14 +02:00
|
|
|
#include <QCommandLineParser>
|
2022-07-07 13:11:51 +02:00
|
|
|
|
|
|
|
int main(int argc, char *argv[]) {
|
|
|
|
QApplication app(argc, argv);
|
2022-07-09 22:07:14 +02:00
|
|
|
QApplication::setApplicationName("discord-screenaudio");
|
2022-07-28 17:34:54 +02:00
|
|
|
QApplication::setApplicationVersion(DISCORD_SCEENAUDIO_VERSION_FULL);
|
2022-07-09 22:07:14 +02:00
|
|
|
|
|
|
|
QCommandLineParser parser;
|
|
|
|
parser.setApplicationDescription(
|
|
|
|
"Custom Discord client with the ability to stream audio on Linux");
|
|
|
|
parser.addHelpOption();
|
|
|
|
parser.addVersionOption();
|
|
|
|
QCommandLineOption virtmicOption("virtmic", "Start the Virtual Microphone",
|
|
|
|
"target");
|
|
|
|
parser.addOption(virtmicOption);
|
|
|
|
#ifdef DEBUG
|
|
|
|
parser.addOption(QCommandLineOption(
|
|
|
|
"remote-debugging-port", "Chromium Remote Debugging Port", "port"));
|
|
|
|
#endif
|
|
|
|
parser.process(app);
|
|
|
|
|
|
|
|
if (parser.isSet(virtmicOption)) {
|
|
|
|
Virtmic::start(parser.value(virtmicOption));
|
|
|
|
}
|
|
|
|
|
2022-07-07 13:11:51 +02:00
|
|
|
MainWindow w;
|
|
|
|
w.show();
|
|
|
|
|
|
|
|
return app.exec();
|
|
|
|
}
|