Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion packages/client/src/devices/MicrophoneManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ export class MicrophoneManager extends AudioDeviceManager<MicrophoneManagerState
const devices = await firstValueFrom(this.listDevices());
const label = devices.find((d) => d.deviceId === deviceId)?.label;

let lastCapturesAudio: boolean | undefined;
this.noAudioDetectorCleanup = createNoAudioDetector(mediaStream, {
noAudioThresholdMs: this.silenceThresholdMs,
emitIntervalMs: this.silenceThresholdMs,
Expand All @@ -169,7 +170,12 @@ export class MicrophoneManager extends AudioDeviceManager<MicrophoneManagerState
deviceId,
label,
};
this.call.tracer.trace('mic.capture_report', event);

if (capturesAudio !== lastCapturesAudio) {
lastCapturesAudio = capturesAudio;
this.call.tracer.trace('mic.capture_report', event);
}

this.call.streamClient.dispatchEvent(event);
},
});
Expand Down
Loading