feat: Implement an Electron-based broadcasting client with screen/window and audio source selection, including Pipewire integration, and add auto-unmute to the viewer.
This commit is contained in:
12
client/test-devices.js
Normal file
12
client/test-devices.js
Normal file
@@ -0,0 +1,12 @@
|
||||
const { app, BrowserWindow } = require('electron');
|
||||
app.whenReady().then(() => {
|
||||
const win = new BrowserWindow({ show: false });
|
||||
win.webContents.executeJavaScript(`
|
||||
navigator.mediaDevices.getUserMedia({audio:true}).then(() =>
|
||||
navigator.mediaDevices.enumerateDevices()
|
||||
).then(devices => devices.map(d => d.label))
|
||||
`).then(labels => {
|
||||
console.log("LABELS:", labels.filter(l => l.toLowerCase().includes('screenshare')));
|
||||
app.quit();
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user