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

Method stopAudio

app/src/utils/tauriStreamCapture.ts:1393–1410  ·  view source on GitHub ↗

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

()

Source from the content-addressed store, hash-verified

1391 * Works on desktop (macOS) and iOS.
1392 */
1393 async stopAudio(): Promise<void> {
1394 if (!isTauri()) {
1395 throw new Error('Audio capture only available in Tauri');
1396 }
1397
1398 try {
1399 if (isDesktop()) {
1400 await invoke('sc_stop_audio');
1401 } else {
1402 // iOS: Stop audio stream and broadcast
1403 await invoke('stop_audio_stream_cmd');
1404 await invoke('plugin:screen-capture|stop_capture_cmd');
1405 }
1406 this.latestAudioData = null;
1407 } catch (error) {
1408 throw error;
1409 }
1410 }
1411
1412 /**
1413 * 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