MCPcopy Create free account
hub / github.com/Roy3838/Observer / stopAudio

Method stopAudio

app/src/utils/tauriStreamCapture.ts:1371–1388  ·  view source on GitHub ↗

* Stop only audio capture. * Works on desktop (macOS) and iOS.

()

Source from the content-addressed store, hash-verified

1369 * Works on desktop (macOS) and iOS.
1370 */
1371 async stopAudio(): Promise<void> {
1372 if (!isTauri()) {
1373 throw new Error('Audio capture only available in Tauri');
1374 }
1375
1376 try {
1377 if (isDesktop()) {
1378 await invoke('sc_stop_audio');
1379 } else {
1380 // iOS: Stop audio stream and broadcast
1381 await invoke('stop_audio_stream_cmd');
1382 await invoke('plugin:screen-capture|stop_capture_cmd');
1383 }
1384 this.latestAudioData = null;
1385 } catch (error) {
1386 throw error;
1387 }
1388 }
1389
1390 /**
1391 * Unified status + frame query - the single source of truth for broadcast state.

Callers

nothing calls this directly

Calls 2

isTauriFunction · 0.90
isDesktopFunction · 0.90

Tested by

no test coverage detected