Skip to content
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ tracing = "0.1.41"
futures = "0.3.31"

cidre = { git = "https://github.com/CapSoftware/cidre", rev = "bf84b67079a8", features = [
"macos_13_0",
"macos_12_7",
"cv",
"cf",
"core_audio",
Expand Down
1 change: 1 addition & 0 deletions apps/desktop/src-tauri/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1873,6 +1873,7 @@ pub async fn run(recording_logging_handle: LoggingHandle, logs_dir: PathBuf) {
show_window,
write_clipboard_string,
platform::perform_haptic_feedback,
platform::is_system_audio_capture_supported,
list_fails,
set_fail,
update_auth_plan,
Expand Down
20 changes: 20 additions & 0 deletions apps/desktop/src-tauri/src/platform/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,23 @@ pub fn perform_haptic_feedback(
#[cfg(not(target_os = "macos"))]
Err("Haptics are only supported on macOS.".into())
}

/// Check if system audio capture is supported on the current platform and OS version.
/// On macOS, system audio capture requires macOS 13.0 or later.
/// On Windows/Linux, this may have different requirements.
#[tauri::command]
#[specta::specta]
#[instrument]
pub fn is_system_audio_capture_supported() -> bool {
#[cfg(target_os = "macos")]
{
scap_screencapturekit::is_system_audio_supported()
}

#[cfg(not(target_os = "macos"))]
{
// On Windows/Linux, we assume system audio capture is available
// This can be refined later based on platform-specific requirements
true
}
}
Loading