mirror of https://github.com/jetkvm/kvm.git
Compare commits
2 Commits
450836daba
...
0f43a84551
| Author | SHA1 | Date |
|---|---|---|
|
|
0f43a84551 | |
|
|
557b3bf3e6 |
|
|
@ -752,7 +752,6 @@ void *run_detect_format(void *arg)
|
||||||
|
|
||||||
while (!should_exit)
|
while (!should_exit)
|
||||||
{
|
{
|
||||||
ensure_sleep_mode_disabled();
|
|
||||||
|
|
||||||
memset(&dv_timings, 0, sizeof(dv_timings));
|
memset(&dv_timings, 0, sizeof(dv_timings));
|
||||||
if (ioctl(sub_dev_fd, VIDIOC_QUERY_DV_TIMINGS, &dv_timings) != 0)
|
if (ioctl(sub_dev_fd, VIDIOC_QUERY_DV_TIMINGS, &dv_timings) != 0)
|
||||||
|
|
|
||||||
|
|
@ -534,21 +534,25 @@ export default function KvmIdRoute() {
|
||||||
|
|
||||||
const audioTransceiver = pc.addTransceiver("audio", { direction: "sendrecv" });
|
const audioTransceiver = pc.addTransceiver("audio", { direction: "sendrecv" });
|
||||||
|
|
||||||
navigator.mediaDevices.getUserMedia({
|
if (navigator.mediaDevices && navigator.mediaDevices.getUserMedia) {
|
||||||
audio: {
|
navigator.mediaDevices.getUserMedia({
|
||||||
echoCancellation: true,
|
audio: {
|
||||||
noiseSuppression: true,
|
echoCancellation: true,
|
||||||
autoGainControl: true,
|
noiseSuppression: true,
|
||||||
channelCount: 2, // Request stereo input if available
|
autoGainControl: true,
|
||||||
}
|
channelCount: 2, // Request stereo input if available
|
||||||
}).then((stream) => {
|
}
|
||||||
const audioTrack = stream.getAudioTracks()[0];
|
}).then((stream) => {
|
||||||
if (audioTrack && audioTransceiver.sender) {
|
const audioTrack = stream.getAudioTracks()[0];
|
||||||
audioTransceiver.sender.replaceTrack(audioTrack);
|
if (audioTrack && audioTransceiver.sender) {
|
||||||
}
|
audioTransceiver.sender.replaceTrack(audioTrack);
|
||||||
}).catch((err) => {
|
}
|
||||||
console.warn("Microphone access denied or unavailable:", err.message);
|
}).catch((err) => {
|
||||||
});
|
console.warn("Microphone access denied or unavailable:", err.message);
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
console.warn("navigator.mediaDevices.getUserMedia is not available in this browser/context");
|
||||||
|
}
|
||||||
|
|
||||||
const rpcDataChannel = pc.createDataChannel("rpc");
|
const rpcDataChannel = pc.createDataChannel("rpc");
|
||||||
rpcDataChannel.onclose = () => console.log("rpcDataChannel has closed");
|
rpcDataChannel.onclose = () => console.log("rpcDataChannel has closed");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue