fix: enable audio capture
This commit is contained in:
@@ -584,8 +584,14 @@ impl ObsContext {
|
|||||||
info!("[GAME_CAPTURE] Using 'Any' mode to capture fullscreen games...");
|
info!("[GAME_CAPTURE] Using 'Any' mode to capture fullscreen games...");
|
||||||
|
|
||||||
// Wrap source build in catch_unwind
|
// Wrap source build in catch_unwind
|
||||||
|
// Enable capture_audio so the game capture source automatically creates
|
||||||
|
// an "Application Audio Capture" (WASAPI) source for the captured game.
|
||||||
let source_result = std::panic::catch_unwind(std::panic::AssertUnwindSafe(|| {
|
let source_result = std::panic::catch_unwind(std::panic::AssertUnwindSafe(|| {
|
||||||
builder.set_capture_mode(ObsGameCaptureMode::Any).build()
|
builder
|
||||||
|
.set_capture_mode(ObsGameCaptureMode::Any)
|
||||||
|
.set_capture_audio(true)
|
||||||
|
.expect("[GAME_CAPTURE] Audio capture not available on this system")
|
||||||
|
.build()
|
||||||
}));
|
}));
|
||||||
|
|
||||||
let source = match source_result {
|
let source = match source_result {
|
||||||
|
|||||||
Reference in New Issue
Block a user